Documentation ¶
Index ¶
Constants ¶
View Source
const ( RootUsername = "root" VCAPUsername = "vcap" AdminGroup = "admin" SudoersGroup = "bosh_sudoers" EphemeralUserPrefix = "bosh_" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DefaultNetworkResolver ¶
type DiskSettings ¶
type Disks ¶
type Disks struct { // e.g "/dev/sda", "1" System string `json:"system"` // Older CPIs returned disk settings as string // e.g "/dev/sdb", "2" // Newer CPIs will populate it in a hash // e.g {"path" => "/dev/sdc", "volume_id" => "3"} Ephemeral interface{} `json:"ephemeral"` // Older CPIs returned disk settings as strings // e.g {"disk-3845-43758-7243-38754" => "/dev/sdc"} // {"disk-3845-43758-7243-38754" => "3"} // Newer CPIs will populate it in a hash: // e.g {"disk-3845-43758-7243-38754" => {"path" => "/dev/sdc"}} // {"disk-3845-43758-7243-38754" => {"volume_id" => "3"}} Persistent map[string]interface{} `json:"persistent"` RawEphemeral []DiskSettings `json:"raw_ephemeral"` }
type Env ¶
type Env struct { Bosh BoshEnv `json:"bosh"` PersistentDiskFS disk.FileSystemType `json:"persistent_disk_fs"` }
func (Env) GetKeepRootPassword ¶
func (Env) GetPassword ¶
func (Env) GetRemoveDevTools ¶
type Network ¶
type Network struct { Type NetworkType `json:"type"` IP string `json:"ip"` Netmask string `json:"netmask"` Gateway string `json:"gateway"` Resolved bool `json:"resolved"` // was resolved via DHCP UseDHCP bool `json:"use_dhcp"` Default []string `json:"default"` DNS []string `json:"dns"` Mac string `json:"mac"` Preconfigured bool `json:"preconfigured"` }
func (Network) IsDefaultFor ¶
type NetworkType ¶
type NetworkType string
const ( NetworkTypeDynamic NetworkType = "dynamic" NetworkTypeVIP NetworkType = "vip" )
type Service ¶
type Service interface { LoadSettings() error // GetSettings does not return error because without settings Agent cannot start. GetSettings() Settings PublicSSHKeyForUsername(string) (string, error) InvalidateSettings() error }
func NewService ¶
func NewService( fs boshsys.FileSystem, settingsPath string, settingsSource Source, defaultNetworkResolver DefaultNetworkResolver, logger boshlog.Logger, ) (service Service)
type Settings ¶
type Settings struct { AgentID string `json:"agent_id"` Blobstore Blobstore `json:"blobstore"` Disks Disks `json:"disks"` Env Env `json:"env"` Networks Networks `json:"networks"` Ntp []string `json:"ntp"` Mbus string `json:"mbus"` VM VM `json:"vm"` TrustedCerts string `json:"trusted_certs"` }
func (Settings) EphemeralDiskSettings ¶
func (s Settings) EphemeralDiskSettings() DiskSettings
func (Settings) PersistentDiskSettings ¶
func (s Settings) PersistentDiskSettings(diskID string) (DiskSettings, bool)
func (Settings) RawEphemeralDiskSettings ¶
func (s Settings) RawEphemeralDiskSettings() (devices []DiskSettings)
Click to show internal directories.
Click to hide internal directories.