cistore

package
v1.4.10 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 25, 2026 License: MIT Imports: 3 Imported by: 2 modules, 4 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CloudConfigFile

type CloudConfigFile struct {
	Content  []byte `` /* 486-byte string literal not displayed */
	Name     string `json:"filename" yaml:"filename"`
	Encoding string `json:"encoding,omitempty" yaml:"encoding,omitempty" enums:"base64,plain"`
}

func (CloudConfigFile) MarshalJSON

func (f CloudConfigFile) MarshalJSON() ([]byte, error)

Custom marshaler for CloudConfigFile

func (*CloudConfigFile) UnmarshalJSON

func (f *CloudConfigFile) UnmarshalJSON(data []byte) error

UnmarshalJSON implements json.Unmarshaler

type ClusterDefaults

type ClusterDefaults struct {
	CloudProvider    string   `json:"cloud_provider,omitempty" yaml:"cloud-provider,omitempty"`
	Region           string   `json:"region,omitempty" yaml:"region,omitempty"`
	AvailabilityZone string   `json:"availability-zone,omitempty" yaml:"availability-zone,omitempty"`
	ClusterName      string   `` /* 187-byte string literal not displayed */
	PublicKeys       []string `` /* 261-byte string literal not displayed */
	BaseUrl          string   `json:"base-url,omitempty" yaml:"base-url,omitempty" example:"http://demo.openchami.cluster:8081/cloud-init"`
	BootSubnet       string   `json:"boot-subnet,omitempty" yaml:"boot-subnet,omitempty"`
	WGSubnet         string   `json:"wg-subnet,omitempty" yaml:"wg-subnet,omitempty"`
	ShortName        string   `` /* 206-byte string literal not displayed */
	NidLength        int      `json:"nid-length,omitempty" yaml:"nid-length,omitempty" example:"3" description:"Width of digits for node ID"`
}

ClusterDefaults represents the possible meta-data that can be set as default values for a cluster.

type GroupData

type GroupData struct {
	Name        string                 `json:"name" yaml:"name" example:"compute" description:"Group name"`
	Description string                 `` /* 132-byte string literal not displayed */
	Data        map[string]interface{} `` /* 143-byte string literal not displayed */
	File        CloudConfigFile        `json:"file,omitempty" yaml:"file,omitempty" description:"Cloud-Init configuration for group"`
	Versions    map[string]string      `json:"versions,omitempty" yaml:"versions,omitempty" description:"Map of group versions"`
}

func (*GroupData) ParseFromJSON

func (g *GroupData) ParseFromJSON(body []byte) error

type OpenCHAMIComponent

type OpenCHAMIComponent struct {
	base.Component
	MAC  string `json:"mac"`            // MAC address of the inteface used to boot the component
	IP   string `json:"ip"`             // IP address of the interface used to boot the component
	WGIP string `json:"wgip,omitempty"` // Wireguard IP address of the interface used for cloud-init
}

type OpenCHAMIInstanceInfo

type OpenCHAMIInstanceInfo struct {
	ID               string   `` /* 159-byte string literal not displayed */
	InstanceID       string   `json:"instance-id" yaml:"instance-id"`
	LocalHostname    string   `json:"local-hostname,omitempty" yaml:"local-hostname" example:"compute-1" description:"Node-specific hostname"`
	Hostname         string   `json:"hostname,omitempty" yaml:"hostname"`
	ClusterName      string   `` /* 177-byte string literal not displayed */
	Region           string   `json:"region,omitempty" yaml:"region"`
	AvailabilityZone string   `json:"availability-zone,omitempty" yaml:"availability-zone"`
	CloudProvider    string   `json:"cloud-provider,omitempty" yaml:"cloud-provider"`
	InstanceType     string   `json:"instance-type,omitempty" yaml:"instance-type"`
	CloudInitBaseURL string   `json:"cloud-init-base-url,omitempty" yaml:"cloud-init-base-url"`
	PublicKeys       []string `` /* 261-byte string literal not displayed */
}

type Store

type Store interface {
	// groups API
	GetGroups() map[string]GroupData
	AddGroupData(groupName string, groupData GroupData) error
	GetGroupData(groupName string) (GroupData, error)
	UpdateGroupData(groupName string, groupData GroupData, create bool) error
	RemoveGroupData(groupName string) error
	// Extended Instance Information API
	GetInstanceInfo(nodeName string) (OpenCHAMIInstanceInfo, error)
	SetInstanceInfo(nodeName string, instanceInfo OpenCHAMIInstanceInfo) error
	DeleteInstanceInfo(nodeName string) error
	// Cluster Defaults
	GetClusterDefaults() (ClusterDefaults, error)
	SetClusterDefaults(clusterDefaults ClusterDefaults) error
}

ciStore is an interface for storing cloud-init entries

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL