Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // C stores the actual configured values, defaults shown below C = Config{ Bind: ":8080", BridgeInterface: "br0", ImageFormat: "qcow2", Bootstrap: Bootstrap{ ContainerRegistry: "docker.io", VMBaseImage: "https://cloud.debian.org/images/cloud/bookworm/daily/latest/debian-12-backports-generic-amd64-daily.qcow2", IncompleteFile: "/var/entanglement.garden/bootstrap-incomplete", }, WANBridge: "brwan", DiskStoragePool: "default", ImageDir: "/var/lib/libvirt/images", ImageHost: "http://image-host.fruit-0.entanglement.garden", ImageCache: fmt.Sprintf("%s/.cache/rhyzome/images/", os.Getenv("HOME")), MetadataURL: "http://169.254.169.254", HTTPBind: ":8080", GRPCPort: 9090, SqlitePath: "/var/rhyzome/rhyzome.db", MACPrefix: "52:54:00", SharedDir: "/var/run/rhyzome-agent", } )
Functions ¶
func GetFakeHosts ¶
func GetFakeHosts() []string
Types ¶
type Bootstrap ¶
type Bootstrap struct { ExitOnSuccess bool `json:"exit_on_success,omitempty"` // used for CI, will also cause VM serial output to come out in our logs BootstrapCluster bool `json:"bootstrap_cluster,omitempty"` // set to true to run cluster bootstrapping ContainerRegistry string `json:"container_registry,omitempty"` // the container registry to use for the bootstrap cluster SSHAuthorizedKeys []string `json:"ssh_authorized_keys,omitempty"` // SSH keys to add to the service VM VMBaseImage string `json:"vm_base_image,omitempty"` // the base image to use for the service VM PublicIP string `json:"public_ip"` // the public IP to use PublicSubnet string `json:"public_subnet"` // the public subnet to use, passed to entanglement-networking PublicGateway string `json:"public_gateway"` // the IP of the gateway to route public traffic to, passed to entanglement-networking ServiceInstance string `json:"services_instance"` // the ID of the instance libvirt-rhyzome-server is running on IncompleteFile string `json:"incomplete_file"` // a file whos presence indicates bootstrapping is not complete AptMirrors []cloudinit.AptMirror `json:"apt_mirrors,omitempty"` // optionally provide custom apt mirrors HypervisorID string `json:"hypervisor_id"` HypervisorNicID string `json:"hypervisor_nic_id"` HypervisorMAC string `json:"hypervisor_mac"` }
type Config ¶
type Config struct { // Server options Bind string `json:"bind,omitempty"` // Bind is the address (and port) to bind the GRPC server to HTTPBind string `json:"http_bind,omitempty"` GRPCPort int `json:"grpc_port,omitempty"` SqlitePath string `json:"sqlite_path,omitempty"` // SqlitePath is the path to the sqlite database file ImageFormat string `json:"image_format,omitempty"` // ImageFormat is `qcow2` if qcow2 files should be uploaded to created volumes, otherwise `raw` // agent options BridgeInterface string `json:"bridge_interface,omitempty"` // BridgeInterface was the bridge that all network interfaces are added to and is still used for some things WANBridge string `json:"wan_interface,omitempty"` // WANBridge is the bridge interface on the host to use for WAN interfaces on routers. Ignored if WANNetwork is specified. ImageDir string `json:"image_dir,omitempty"` // ImageDir is the path to the local image pool DiskStoragePool string `json:"disk_storage_pool,omitempty"` // DiskStoragePool is the name of the storage pool to use ImageCache string `json:"image_cache,omitempty"` // ImageCache is the path on the local disk to a folder where images should be cached ImageHost string `json:"imagehost,omitempty"` // ImageHost is the base URL for the disk image server MetadataURL string `json:"metadata_url,omitempty"` APIServer string `json:"apiserver,omitempty"` // The host:port of the gRPC server to connect to // shared MACPrefix string `json:"mac_prefix,omitempty"` PKI grpcx.PKI `json:"pki,omitempty"` // used for gRPC mTLS Domain string `json:"domain"` // the system's root domain Bootstrap Bootstrap `json:"bootstrap,omitempty"` // Bootstrap tells us how to bootstrap the a new cluster (and if we should) - used by server and agent because both need to access bootstrap.Domain, which IMO should just be moved out of bootstrap }
Config describes all configurable keys
Click to show internal directories.
Click to hide internal directories.