Documentation ¶
Index ¶
- Variables
- type Config
- type ConfigReference
- type Create
- type Disk
- type Docker
- type Etcd
- type Etcd2
- type Etcd3_0
- type Etcd3_1
- type EtcdVersion
- type File
- type FileContents
- type FileGroup
- type FileUser
- type Filesystem
- type Flannel
- type Flannel0_5
- type Flannel0_6
- type Flannel0_7
- type FlannelVersion
- type Group
- type Hash
- type Ignition
- type IgnitionConfig
- type Locksmith
- type Mount
- type Networkd
- type NetworkdUnit
- type Options
- type Partition
- type Passwd
- type Raid
- type RebootStrategy
- type Remote
- type Storage
- type Systemd
- type SystemdUnit
- type SystemdUnitDropIn
- type Update
- type UpdateGroup
- type UpdateServer
- type User
- type UserCreate
- type Verification
Constants ¶
This section is empty.
Variables ¶
View Source
var ( EtcdVersionTooOld = errors.New("Etcd version specified is not valid (too old)") EtcdMinorVersionTooNew = errors.New("Etcd minor version specified is too new, only options available in the previous minor version will be accepted") EtcdMajorVersionTooNew = errors.New("Etcd version is not valid (too new)") OldestEtcd = *semver.Must(semver.NewVersion("2.3.0")) EtcdDefaultVersion = *semver.Must(semver.NewVersion("3.0.0")) )
View Source
var ( ErrFlannelTooOld = errors.New("invalid flannel version (too old)") ErrFlannelMinorTooNew = errors.New("flannel minor version too new. Only options available in the previous minor version will be supported") OldestFlannelVersion = *semver.Must(semver.NewVersion("0.5.0")) FlannelDefaultVersion = *semver.Must(semver.NewVersion("0.6.0")) )
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { Ignition *Ignition `yaml:"ignition,omitempty"` Storage *Storage `yaml:"storage,omitempty"` Systemd *Systemd `yaml:"systemd,omitempty"` Networkd *Networkd `yaml:"networkd,omitempty"` Passwd *Passwd `yaml:"passwd,omitempty"` Etcd *Etcd `yaml:"etcd,omitempty"` Flannel *Flannel `yaml:"flannel,omitempty"` Update *Update `yaml:"update,omitempty"` Docker *Docker `yaml:"docker,omitempty"` Locksmith *Locksmith `yaml:"locksmith,omitempty"` }
type ConfigReference ¶
type ConfigReference struct { Source string `yaml:"source,omitempty"` Verification Verification `yaml:"verification,omitempty"` }
type Etcd ¶
type Etcd struct { Version *EtcdVersion `yaml:"version,omitempty"` Options }
Etcd is a stub for yaml unmarshalling that figures out which of the other Etcd structs to use and unmarshals to that. Options needs to be an embedded type so that the structure of the yaml tree matches the structure of the go config tree
func (*Etcd) UnmarshalYAML ¶
type Etcd2 ¶
type Etcd2 struct { AdvertiseClientURLs string `yaml:"advertise_client_urls" cli:"advertise-client-urls"` CAFile string `` /* 141-byte string literal not displayed */ CertFile string `yaml:"cert_file" cli:"cert-file"` ClientCertAuth bool `yaml:"client_cert_auth" cli:"client-cert-auth"` CorsOrigins string `yaml:"cors" cli:"cors"` DataDir string `yaml:"data_dir" cli:"data-dir"` Debug bool `yaml:"debug" cli:"debug"` Discovery string `yaml:"discovery" cli:"discovery"` DiscoveryFallback string `yaml:"discovery_fallback" cli:"discovery-fallback"` DiscoverySRV string `yaml:"discovery_srv" cli:"discovery-srv"` DiscoveryProxy string `yaml:"discovery_proxy" cli:"discovery-proxy"` ElectionTimeout int `yaml:"election_timeout" cli:"election-timeout"` EnablePprof bool `yaml:"enable_pprof" cli:"enable-pprof"` ForceNewCluster bool `yaml:"force_new_cluster" cli:"force-new-cluster"` HeartbeatInterval int `yaml:"heartbeat_interval" cli:"heartbeat-interval"` InitialAdvertisePeerURLs string `yaml:"initial_advertise_peer_urls" cli:"initial-advertise-peer-urls"` InitialCluster string `yaml:"initial_cluster" cli:"initial-cluster"` InitialClusterState string `yaml:"initial_cluster_state" cli:"initial-cluster-state"` InitialClusterToken string `yaml:"initial_cluster_token" cli:"initial-cluster-token"` KeyFile string `yaml:"key_file" cli:"key-file"` ListenClientURLs string `yaml:"listen_client_urls" cli:"listen-client-urls"` ListenPeerURLs string `yaml:"listen_peer_urls" cli:"listen-peer-urls"` LogPackageLevels string `yaml:"log_package_levels" cli:"log-package-levels"` MaxSnapshots int `yaml:"max_snapshots" cli:"max-snapshots"` MaxWALs int `yaml:"max_wals" cli:"max-wals"` Name string `yaml:"name" cli:"name"` PeerCAFile string `` /* 153-byte string literal not displayed */ PeerCertFile string `yaml:"peer_cert_file" cli:"peer-cert-file"` PeerKeyFile string `yaml:"peer_key_file" cli:"peer-key-file"` PeerClientCertAuth bool `yaml:"peer_client_cert_auth" cli:"peer-client-cert-auth"` PeerTrustedCAFile string `yaml:"peer_trusted_ca_file" cli:"peer-trusted-ca-file"` Proxy string `yaml:"proxy" cli:"proxy" valid:"^(on|off|readonly)$"` ProxyDialTimeout int `yaml:"proxy_dial_timeout" cli:"proxy-dial-timeout"` ProxyFailureWait int `yaml:"proxy_failure_wait" cli:"proxy-failure-wait"` ProxyReadTimeout int `yaml:"proxy_read_timeout" cli:"proxy-read-timeout"` ProxyRefreshInterval int `yaml:"proxy_refresh_interval" cli:"proxy-refresh-interval"` ProxyWriteTimeout int `yaml:"proxy_write_timeout" cli:"proxy-write-timeout"` SnapshotCount int `yaml:"snapshot_count" cli:"snapshot-count"` StrictReconfigCheck bool `yaml:"strict_reconfig_check" cli:"strict-reconfig-check"` TrustedCAFile string `yaml:"trusted_ca_file" cli:"trusted-ca-file"` WalDir string `yaml:"wal_dir" cli:"wal-dir"` }
type Etcd3_0 ¶
type Etcd3_0 struct { Name string `yaml:"name" cli:"name"` DataDir string `yaml:"data_dir" cli:"data-dir"` WalDir string `yaml:"wal_dir" cli:"wal-dir"` SnapshotCount int `yaml:"snapshot_count" cli:"snapshot-count"` HeartbeatInterval int `yaml:"heartbeat_interval" cli:"heartbeat-interval"` ElectionTimeout int `yaml:"election_timeout" cli:"election-timeout"` ListenPeerUrls string `yaml:"listen_peer_urls" cli:"listen-peer-urls"` ListenClientUrls string `yaml:"listen_client_urls" cli:"listen-client-urls"` MaxSnapshots int `yaml:"max_snapshots" cli:"max-snapshots"` MaxWals int `yaml:"max_wals" cli:"max-wals"` Cors string `yaml:"cors" cli:"cors"` InitialAdvertisePeerUrls string `yaml:"initial_advertise_peer_urls" cli:"initial-advertise-peer-urls"` InitialCluster string `yaml:"initial_cluster" cli:"initial-cluster"` InitialClusterState string `yaml:"initial_cluster_state" cli:"initial-cluster-state"` InitialClusterToken string `yaml:"initial_cluster_token" cli:"initial-cluster-token"` AdvertiseClientUrls string `yaml:"advertise_client_urls" cli:"advertise-client-urls"` Discovery string `yaml:"discovery" cli:"discovery"` DiscoverySrv string `yaml:"discovery_srv" cli:"discovery-srv"` DiscoveryFallback string `yaml:"discovery_fallback" cli:"discovery-fallback"` DiscoveryProxy string `yaml:"discovery_proxy" cli:"discovery-proxy"` StrictReconfigCheck bool `yaml:"strict_reconfig_check" cli:"strict-reconfig-check"` AutoCompactionRetention int `yaml:"auto_compaction_retention" cli:"auto-compaction-retention"` Proxy string `yaml:"proxy" cli:"proxy"` ProxyFailureWait int `yaml:"proxy_failure_wait" cli:"proxy-failure-wait"` ProxyRefreshInterval int `yaml:"proxy_refresh_interval" cli:"proxy-refresh-interval"` ProxyDialTimeout int `yaml:"proxy_dial_timeout" cli:"proxy-dial-timeout"` ProxyWriteTimeout int `yaml:"proxy_write_timeout" cli:"proxy-write-timeout"` ProxyReadTimeout int `yaml:"proxy_read_timeout" cli:"proxy-read-timeout"` CaFile string `` /* 139-byte string literal not displayed */ CertFile string `yaml:"cert_file" cli:"cert-file"` KeyFile string `yaml:"key_file" cli:"key-file"` ClientCertAuth bool `yaml:"client_cert_auth" cli:"client-cert-auth"` TrustedCaFile string `yaml:"trusted_ca_file" cli:"trusted-ca-file"` AutoTls bool `yaml:"auto_tls" cli:"auto-tls"` PeerCaFile string `` /* 151-byte string literal not displayed */ PeerCertFile string `yaml:"peer_cert_file" cli:"peer-cert-file"` PeerKeyFile string `yaml:"peer_key_file" cli:"peer-key-file"` PeerClientCertAuth bool `yaml:"peer_client_cert_auth" cli:"peer-client-cert-auth"` PeerTrustedCaFile string `yaml:"peer_trusted_ca_file" cli:"peer-trusted-ca-file"` PeerAutoTls bool `yaml:"peer_auto_tls" cli:"peer-auto-tls"` Debug bool `yaml:"debug" cli:"debug"` LogPackageLevels string `yaml:"log_package_levels" cli:"log-package-levels"` ForceNewCluster bool `yaml:"force_new_cluster" cli:"force-new-cluster"` }
type Etcd3_1 ¶
type Etcd3_1 struct { Name string `yaml:"name" cli:"name"` DataDir string `yaml:"data_dir" cli:"data-dir"` WalDir string `yaml:"wal_dir" cli:"wal-dir"` SnapshotCount int `yaml:"snapshot_count" cli:"snapshot-count"` HeartbeatInterval int `yaml:"heartbeat_interval" cli:"heartbeat-interval"` ElectionTimeout int `yaml:"election_timeout" cli:"election-timeout"` ListenPeerUrls string `yaml:"listen_peer_urls" cli:"listen-peer-urls"` ListenClientUrls string `yaml:"listen_client_urls" cli:"listen-client-urls"` MaxSnapshots int `yaml:"max_snapshots" cli:"max-snapshots"` MaxWals int `yaml:"max_wals" cli:"max-wals"` Cors string `yaml:"cors" cli:"cors"` InitialAdvertisePeerUrls string `yaml:"initial_advertise_peer_urls" cli:"initial-advertise-peer-urls"` InitialCluster string `yaml:"initial_cluster" cli:"initial-cluster"` InitialClusterState string `yaml:"initial_cluster_state" cli:"initial-cluster-state"` InitialClusterToken string `yaml:"initial_cluster_token" cli:"initial-cluster-token"` AdvertiseClientUrls string `yaml:"advertise_client_urls" cli:"advertise-client-urls"` Discovery string `yaml:"discovery" cli:"discovery"` DiscoverySrv string `yaml:"discovery_srv" cli:"discovery-srv"` DiscoveryFallback string `yaml:"discovery_fallback" cli:"discovery-fallback"` DiscoveryProxy string `yaml:"discovery_proxy" cli:"discovery-proxy"` StrictReconfigCheck bool `yaml:"strict_reconfig_check" cli:"strict-reconfig-check"` AutoCompactionRetention int `yaml:"auto_compaction_retention" cli:"auto-compaction-retention"` Proxy string `yaml:"proxy" cli:"proxy"` ProxyFailureWait int `yaml:"proxy_failure_wait" cli:"proxy-failure-wait"` ProxyRefreshInterval int `yaml:"proxy_refresh_interval" cli:"proxy-refresh-interval"` ProxyDialTimeout int `yaml:"proxy_dial_timeout" cli:"proxy-dial-timeout"` ProxyWriteTimeout int `yaml:"proxy_write_timeout" cli:"proxy-write-timeout"` ProxyReadTimeout int `yaml:"proxy_read_timeout" cli:"proxy-read-timeout"` CaFile string `` /* 139-byte string literal not displayed */ CertFile string `yaml:"cert_file" cli:"cert-file"` KeyFile string `yaml:"key_file" cli:"key-file"` ClientCertAuth bool `yaml:"client_cert_auth" cli:"client-cert-auth"` TrustedCaFile string `yaml:"trusted_ca_file" cli:"trusted-ca-file"` AutoTls bool `yaml:"auto_tls" cli:"auto-tls"` PeerCaFile string `` /* 151-byte string literal not displayed */ PeerCertFile string `yaml:"peer_cert_file" cli:"peer-cert-file"` PeerKeyFile string `yaml:"peer_key_file" cli:"peer-key-file"` PeerClientCertAuth bool `yaml:"peer_client_cert_auth" cli:"peer-client-cert-auth"` PeerTrustedCaFile string `yaml:"peer_trusted_ca_file" cli:"peer-trusted-ca-file"` PeerAutoTls bool `yaml:"peer_auto_tls" cli:"peer-auto-tls"` Debug bool `yaml:"debug" cli:"debug"` LogPackageLevels string `yaml:"log_package_levels" cli:"log-package-levels"` ForceNewCluster bool `yaml:"force_new_cluster" cli:"force-new-cluster"` Metrics string `yaml:"metrics" cli:"metrics"` LogOutput string `yaml:"log_output" cli:"log-output"` }
type EtcdVersion ¶
func (EtcdVersion) String ¶
func (e EtcdVersion) String() string
func (*EtcdVersion) UnmarshalYAML ¶
func (e *EtcdVersion) UnmarshalYAML(unmarshal func(interface{}) error) error
type FileContents ¶
type Filesystem ¶
type Flannel ¶
type Flannel struct { Version *FlannelVersion `yaml:"version,omitempty"` Options }
func (*Flannel) UnmarshalYAML ¶
type Flannel0_5 ¶
type Flannel0_5 struct { EtcdEndpoints string `yaml:"etcd_endpoints" cli:"etcd-endpoints"` EtcdCAFile string `yaml:"etcd_cafile" cli:"etcd-cafile"` EtcdCertFile string `yaml:"etcd_certfile" cli:"etcd-certfile"` EtcdKeyFile string `yaml:"etcd_keyfile" cli:"etcd-keyfile"` EtcdPrefix string `yaml:"etcd_prefix" cli:"etcd-prefix"` IPMasq string `yaml:"ip_masq" cli:"ip-masq"` SubnetFile string `yaml:"subnet_file" cli:"subnet-file"` Iface string `yaml:"interface" cli:"iface"` PublicIP string `yaml:"public_ip" cli:"public-ip"` }
type Flannel0_6 ¶
type Flannel0_6 struct { EtcdUsername string `yaml:"etcd_username" cli:"etcd-username"` EtcdPassword string `yaml:"etcd_password" cli:"etcd-password"` EtcdEndpoints string `yaml:"etcd_endpoints" cli:"etcd-endpoints"` EtcdCAFile string `yaml:"etcd_cafile" cli:"etcd-cafile"` EtcdCertFile string `yaml:"etcd_certfile" cli:"etcd-certfile"` EtcdKeyFile string `yaml:"etcd_keyfile" cli:"etcd-keyfile"` EtcdPrefix string `yaml:"etcd_prefix" cli:"etcd-prefix"` IPMasq string `yaml:"ip_masq" cli:"ip-masq"` SubnetFile string `yaml:"subnet_file" cli:"subnet-file"` Iface string `yaml:"interface" cli:"iface"` PublicIP string `yaml:"public_ip" cli:"public-ip"` }
type Flannel0_7 ¶
type Flannel0_7 struct { EtcdUsername string `yaml:"etcd_username" cli:"etcd-username"` EtcdPassword string `yaml:"etcd_password" cli:"etcd-password"` EtcdEndpoints string `yaml:"etcd_endpoints" cli:"etcd-endpoints"` EtcdCAFile string `yaml:"etcd_cafile" cli:"etcd-cafile"` EtcdCertFile string `yaml:"etcd_certfile" cli:"etcd-certfile"` EtcdKeyFile string `yaml:"etcd_keyfile" cli:"etcd-keyfile"` EtcdPrefix string `yaml:"etcd_prefix" cli:"etcd-prefix"` IPMasq string `yaml:"ip_masq" cli:"ip-masq"` SubnetFile string `yaml:"subnet_file" cli:"subnet-file"` Iface string `yaml:"interface" cli:"iface"` PublicIP string `yaml:"public_ip" cli:"public-ip"` KubeSubnetMgr bool `yaml:"kube_subnet_mgr" cli:"kube-subnet-mgr"` }
Flannel0_7 represents flannel options for version 0.7.x. Don't embed Flannel0_6 because the yaml parser doesn't handle embedded structs
type FlannelVersion ¶
func (FlannelVersion) String ¶
func (fv FlannelVersion) String() string
func (*FlannelVersion) UnmarshalYAML ¶
func (v *FlannelVersion) UnmarshalYAML(unmarshal func(interface{}) error) error
type Ignition ¶
type Ignition struct {
Config IgnitionConfig `yaml:"config,omitempty"`
}
type IgnitionConfig ¶
type IgnitionConfig struct { Append []ConfigReference `yaml:"append,omitempty"` Replace *ConfigReference `yaml:"replace,omitempty"` }
type Locksmith ¶
type Locksmith struct {
RebootStrategy RebootStrategy `yaml:"reboot_strategy,omitempty"`
}
type Networkd ¶
type Networkd struct {
Units []NetworkdUnit `yaml:"units,omitempty"`
}
type NetworkdUnit ¶
type RebootStrategy ¶
type RebootStrategy string
type Remote ¶
type Remote struct { Url string `yaml:"url,omitempty"` Compression string `yaml:"compression,omitempty"` Verification Verification `yaml:"verification,omitempty"` }
type Storage ¶
type Storage struct { Disks []Disk `yaml:"disks,omitempty"` Arrays []Raid `yaml:"raid,omitempty"` Filesystems []Filesystem `yaml:"filesystems,omitempty"` Files []File `yaml:"files,omitempty"` }
type Systemd ¶
type Systemd struct {
Units []SystemdUnit `yaml:"units,omitempty"`
}
type SystemdUnit ¶
type SystemdUnit struct { Name string `yaml:"name,omitempty"` Enable bool `yaml:"enable,omitempty"` Mask bool `yaml:"mask,omitempty"` Contents string `yaml:"contents,omitempty"` DropIns []SystemdUnitDropIn `yaml:"dropins,omitempty"` }
type SystemdUnitDropIn ¶
type Update ¶
type Update struct { Group UpdateGroup `yaml:"group,omitempty"` Server UpdateServer `yaml:"server,omitempty"` }
type UpdateGroup ¶
type UpdateGroup string
type UpdateServer ¶
type UpdateServer string
type User ¶
type User struct { Name string `yaml:"name,omitempty"` PasswordHash string `yaml:"password_hash,omitempty"` SSHAuthorizedKeys []string `yaml:"ssh_authorized_keys,omitempty"` Create *UserCreate `yaml:"create,omitempty"` }
type UserCreate ¶
type UserCreate struct { Uid *uint `yaml:"uid,omitempty"` GECOS string `yaml:"gecos,omitempty"` Homedir string `yaml:"home_dir,omitempty"` NoCreateHome bool `yaml:"no_create_home,omitempty"` PrimaryGroup string `yaml:"primary_group,omitempty"` Groups []string `yaml:"groups,omitempty"` NoUserGroup bool `yaml:"no_user_group,omitempty"` System bool `yaml:"system,omitempty"` NoLogInit bool `yaml:"no_log_init,omitempty"` Shell string `yaml:"shell,omitempty"` }
type Verification ¶
type Verification struct {
Hash Hash `yaml:"hash,omitempty"`
}
Click to show internal directories.
Click to hide internal directories.