Documentation
¶
Index ¶
- func CoreosArch() string
- func CreateIgnition(ignitionFile string, publicKey string, user string, password string) error
- func CreateSSHKeys(publicKeyFile, privateKeyFile string) (string, error)
- func Decompress(localPath string) (string, error)
- func DownloadVMImage(downloadURL string, localImagePath string) error
- func IsHostPortAvailable(host string, port int) bool
- func IsPortAvailable(port int) bool
- type ArtifactFormat
- type Clevis
- type Config
- type Custom
- type Device
- type Directory
- type DirectoryEmbedded1
- type Disk
- type Dropin
- type FcosDownload
- type File
- type FileEmbedded1
- type Filesystem
- type FilesystemOption
- type Group
- type HTTPHeader
- type HTTPHeaders
- type Ignition
- type IgnitionConfig
- type Link
- type LinkEmbedded1
- type Luks
- type LuksOption
- type MountOption
- type NoProxyItem
- type Node
- type NodeGroup
- type NodeUser
- type Partition
- type Passwd
- type PasswdGroup
- type PasswdUser
- type Proxy
- type Raid
- type RaidOption
- type Resource
- type SSHAuthorizedKey
- type Security
- type Storage
- type Systemd
- type TLS
- type Tang
- type Timeouts
- type Unit
- type Verification
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CoreosArch ¶
func CoreosArch() string
as of 2024-05-28, these are the 4 architectures available in curl https://builds.coreos.fedoraproject.org/streams/next.json
func CreateIgnition ¶
func CreateSSHKeys ¶
func Decompress ¶
func DownloadVMImage ¶
DownloadVMImage downloads a VM image from url to given path with download status
func IsHostPortAvailable ¶
func IsPortAvailable ¶
Types ¶
type ArtifactFormat ¶
type Directory ¶
type Directory struct {
Node
DirectoryEmbedded1
}
type DirectoryEmbedded1 ¶
type DirectoryEmbedded1 struct {
Mode *int `json:"mode,omitempty"`
}
type FcosDownload ¶
type FcosDownload struct {
DataDir string
}
func NewFcosDownloader ¶
func NewFcosDownloader(dataDir string) (*FcosDownload, error)
func (*FcosDownload) DownloadImage ¶
func (downloader *FcosDownload) DownloadImage(artifactType string, formatType string) (string, error)
type File ¶
type File struct {
Node
FileEmbedded1
}
type FileEmbedded1 ¶
type Filesystem ¶
type Filesystem struct {
Device string `json:"device"`
Format *string `json:"format,omitempty"`
Label *string `json:"label,omitempty"`
MountOptions []MountOption `json:"mountOptions,omitempty"`
Options []FilesystemOption `json:"options,omitempty"`
Path *string `json:"path,omitempty"`
UUID *string `json:"uuid,omitempty"`
WipeFilesystem *bool `json:"wipeFilesystem,omitempty"`
}
type FilesystemOption ¶
type FilesystemOption string
type HTTPHeader ¶
type HTTPHeaders ¶
type HTTPHeaders []HTTPHeader
type Ignition ¶
type Ignition struct {
Config IgnitionConfig `json:"config,omitempty"`
Proxy Proxy `json:"proxy,omitempty"`
Security Security `json:"security,omitempty"`
Timeouts Timeouts `json:"timeouts,omitempty"`
Version string `json:"version,omitempty"`
}
type IgnitionConfig ¶
type Link ¶
type Link struct {
Node
LinkEmbedded1
}
type LinkEmbedded1 ¶
type Luks ¶
type Luks struct {
Clevis *Clevis `json:"clevis,omitempty"`
Device *string `json:"device,omitempty"`
KeyFile Resource `json:"keyFile,omitempty"`
Label *string `json:"label,omitempty"`
Name string `json:"name"`
Options []LuksOption `json:"options,omitempty"`
UUID *string `json:"uuid,omitempty"`
WipeVolume *bool `json:"wipeVolume,omitempty"`
}
type LuksOption ¶
type LuksOption string
type MountOption ¶
type MountOption string
type NoProxyItem ¶
type NoProxyItem string
type Partition ¶
type Partition struct {
GUID *string `json:"guid,omitempty"`
Label *string `json:"label,omitempty"`
Number int `json:"number,omitempty"`
Resize *bool `json:"resize,omitempty"`
ShouldExist *bool `json:"shouldExist,omitempty"`
SizeMiB *int `json:"sizeMiB,omitempty"`
StartMiB *int `json:"startMiB,omitempty"`
TypeGUID *string `json:"typeGuid,omitempty"`
WipePartitionEntry *bool `json:"wipePartitionEntry,omitempty"`
}
type Passwd ¶
type Passwd struct {
Groups []PasswdGroup `json:"groups,omitempty"`
Users []PasswdUser `json:"users,omitempty"`
}
type PasswdGroup ¶
type PasswdUser ¶
type PasswdUser struct {
Gecos *string `json:"gecos,omitempty"`
Groups []Group `json:"groups,omitempty"`
HomeDir *string `json:"homeDir,omitempty"`
Name string `json:"name"`
NoCreateHome *bool `json:"noCreateHome,omitempty"`
NoLogInit *bool `json:"noLogInit,omitempty"`
NoUserGroup *bool `json:"noUserGroup,omitempty"`
PasswordHash *string `json:"passwordHash,omitempty"`
PrimaryGroup *string `json:"primaryGroup,omitempty"`
SSHAuthorizedKeys []SSHAuthorizedKey `json:"sshAuthorizedKeys,omitempty"`
Shell *string `json:"shell,omitempty"`
ShouldExist *bool `json:"shouldExist,omitempty"`
System *bool `json:"system,omitempty"`
UID *int `json:"uid,omitempty"`
}
type Proxy ¶
type Proxy struct {
HTTPProxy *string `json:"httpProxy,omitempty"`
HTTPSProxy *string `json:"httpsProxy,omitempty"`
NoProxy []NoProxyItem `json:"noProxy,omitempty"`
}
type Raid ¶
type Raid struct {
Devices []Device `json:"devices"`
Level string `json:"level"`
Name string `json:"name"`
Options []RaidOption `json:"options,omitempty"`
Spares *int `json:"spares,omitempty"`
}
type RaidOption ¶
type RaidOption string
type Resource ¶
type Resource struct {
Compression *string `json:"compression,omitempty"`
HTTPHeaders HTTPHeaders `json:"httpHeaders,omitempty"`
Source *string `json:"source,omitempty"`
Verification Verification `json:"verification,omitempty"`
}
type SSHAuthorizedKey ¶
type SSHAuthorizedKey string
type Storage ¶
type Storage struct {
Directories []Directory `json:"directories,omitempty"`
Disks []Disk `json:"disks,omitempty"`
Files []File `json:"files,omitempty"`
Filesystems []Filesystem `json:"filesystems,omitempty"`
Links []Link `json:"links,omitempty"`
Luks []Luks `json:"luks,omitempty"`
Raid []Raid `json:"raid,omitempty"`
}
type TLS ¶
type TLS struct {
CertificateAuthorities []Resource `json:"certificateAuthorities,omitempty"`
}
type Verification ¶
type Verification struct {
Hash *string `json:"hash,omitempty"`
}
Click to show internal directories.
Click to hide internal directories.