Documentation
¶
Index ¶
- Variables
- func NewToBool() mapper.Mapper
- func NewToMap() mapper.Mapper
- func NewToSlice() mapper.Mapper
- func NewTypeConverter(fieldType string, converter Converter) mapper.Mapper
- func PrintInstall(cfg CloudConfig) ([]byte, error)
- func ToBytes(cfg CloudConfig) ([]byte, error)
- func ToEnv(cfg CloudConfig) ([]string, error)
- func Write(cfg CloudConfig, writer io.Writer) error
- type CloudConfig
- type Converter
- type File
- type FuzzyNames
- type Install
- type K3OS
- type Wifi
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // SystemConfig is the default system configuration SystemConfig = system.RootPath("config.yaml") // LocalConfig is the local system configuration LocalConfig = system.LocalPath("config.yaml") )
Functions ¶
func NewToSlice ¶
func PrintInstall ¶
func PrintInstall(cfg CloudConfig) ([]byte, error)
func ToBytes ¶
func ToBytes(cfg CloudConfig) ([]byte, error)
func ToEnv ¶
func ToEnv(cfg CloudConfig) ([]string, error)
Types ¶
type CloudConfig ¶
type CloudConfig struct {
SSHAuthorizedKeys []string `json:"sshAuthorizedKeys,omitempty"`
WriteFiles []File `json:"writeFiles,omitempty"`
Hostname string `json:"hostname,omitempty"`
K3OS K3OS `json:"k3os,omitempty"`
Runcmd []string `json:"runCmd,omitempty"`
Bootcmd []string `json:"bootCmd,omitempty"`
Initcmd []string `json:"initCmd,omitempty"`
}
func ReadConfig ¶
func ReadConfig() (CloudConfig, error)
type File ¶
type FuzzyNames ¶
type FuzzyNames struct {
mappers.DefaultMapper
// contains filtered or unexported fields
}
func (*FuzzyNames) ModifySchema ¶
func (*FuzzyNames) ToInternal ¶
func (f *FuzzyNames) ToInternal(data map[string]interface{}) error
type Install ¶
type Install struct {
ForceEFI bool `json:"forceEfi,omitempty"`
Device string `json:"device,omitempty"`
ConfigURL string `json:"configUrl,omitempty"`
Silent bool `json:"silent,omitempty"`
ISOURL string `json:"isoUrl,omitempty"`
PowerOff bool `json:"powerOff,omitempty"`
NoFormat bool `json:"noFormat,omitempty"`
Debug bool `json:"debug,omitempty"`
TTY string `json:"tty,omitempty"`
}
type K3OS ¶
type K3OS struct {
DataSources []string `json:"dataSources,omitempty"`
Modules []string `json:"modules,omitempty"`
Sysctls map[string]string `json:"sysctls,omitempty"`
NTPServers []string `json:"ntpServers,omitempty"`
DNSNameservers []string `json:"dnsNameservers,omitempty"`
Wifi []Wifi `json:"wifi,omitempty"`
Password string `json:"password,omitempty"`
ServerURL string `json:"serverUrl,omitempty"`
Token string `json:"token,omitempty"`
Labels map[string]string `json:"labels,omitempty"`
K3sArgs []string `json:"k3sArgs,omitempty"`
Environment map[string]string `json:"environment,omitempty"`
Taints []string `json:"taints,omitempty"`
Install *Install `json:"install,omitempty"`
}
Click to show internal directories.
Click to hide internal directories.