imagebased

package
v0.91.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 24, 2024 License: Apache-2.0 Imports: 3 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

View Source
const (
	// SeedReconfigurationVersion is the current version of the
	// SeedReconfiguration struct.
	SeedReconfigurationVersion = 1

	// BlockDeviceLabel is the volume label to be used for the image-based
	// installer configuration ISO.
	BlockDeviceLabel = "cluster-config"
)
View Source
const (
	// ImageBasedConfigVersion is the version supported by this package.
	ImageBasedConfigVersion = "v1beta1"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type AdditionalTrustBundle

type AdditionalTrustBundle struct {
	// UserCaBundle keeps the contents of the user-ca-bundle ConfigMap in the
	// openshift-config namepace.
	UserCaBundle string `json:"userCaBundle"`

	// ProxyConfigmapName is the Proxy CR trustedCA ConfigMap name.
	ProxyConfigmapName string `json:"proxyConfigmapName"`

	// ProxyConfigampBundle keeps the contents of the ProxyConfigmapName ConfigMap.
	// It must be equal to the UserCaBundle when  ProxyConfigmapName is
	// user-ca-bundle.
	ProxyConfigmapBundle string `json:"proxyConfigmapBundle"`
}

AdditionalTrustBundle represents the PEM-encoded X.509 certificate bundle that will be added to the nodes' trusted certificate store.

type ClientAuthCrypto

type ClientAuthCrypto struct {
	// AdminCACertificate is a PEM-encoded X.509 certificate.
	AdminCACertificate string `json:"admin_ca_certificate,omitempty"`
}

ClientAuthCrypto contains the CA certificate used to sign the cluster's cryptographic objects.

type Config

type Config struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	// AdditionalNTPSources is a list of NTP sources (hostname or IP) to be added to all cluster
	// hosts. They are added to any NTP sources that were configured through other means.
	// +optional
	AdditionalNTPSources []string `json:"additionalNTPSources,omitempty"`

	// Hostname is the desired hostname of the SNO node.
	Hostname string `json:"hostname,omitempty"`

	// NetworkConfig is a YAML manifest that can be processed by nmstate, using custom
	// marshaling/unmarshaling that will allow to populate nmstate config as plain yaml.
	// +optional
	NetworkConfig aiv1beta1.NetConfig `json:"networkConfig,omitempty"`

	// ReleaseRegistry is the container registry used to host the release image of the seed cluster.
	// +optional
	ReleaseRegistry string `json:"releaseRegistry,omitempty"`
}

Config is the API for specifying configuration for the image-based configuration ISO.

type IngresssCrypto

type IngresssCrypto struct {
	// IngressCA is a PEM-encoded X.509 certificate.
	IngressCA string `json:"ingress_ca,omitempty"`
}

IngresssCrypto contains the ingrees CA certificate.

type InstallationConfig

type InstallationConfig struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	// AdditionalTrustBundle is a PEM-encoded X.509 certificate bundle
	// that will be added to the nodes' trusted certificate store.
	//
	// +optional
	AdditionalTrustBundle string `json:"additionalTrustBundle,omitempty"`

	// ExtraPartitionLabel label of extra partition used for /var/lib/containers.
	// Default is varlibcontainers
	// +optional
	ExtraPartitionLabel string `json:"extraPartitionLabel,omitempty"`

	// ExtraPartitionNumber number of extra partition used for /var/lib/containers.
	// Default is 5
	// +optional
	ExtraPartitionNumber uint `json:"extraPartitionNumber,omitempty"`

	// ExtraPartitionStart is the start of the /var/lib/containers partition. Free
	// space before it will be allocated to system partition. It can be one of the
	// following:
	//   - Positive number: partition will start at position 120Gb of the disk and extend to the end of the disk. Example: 120Gb
	//   - Negative number: partition will be of that precise size. Example: -40Gb
	// It defaults to -40G (40GB before the end of the disk).
	// +optional
	ExtraPartitionStart string `json:"extraPartitionStart,omitempty"`

	// IgnitionConfigOverride is a JSON string containing the user overrides for
	// the Ignition configuration. It will be merged with the ignition config
	// generated by the image-based installer. Supported Ignition version is 3.2.
	// +optional
	IgnitionConfigOverride string `json:"ignitionConfigOverride,omitempty"`

	// ImageDigestSources lists sources/repositories for the release-image content.
	// +optional
	ImageDigestSources []types.ImageDigestSource `json:"imageDigestSources,omitempty"`

	// InstallationDisk is the disk used to install the seed image. Provide the
	// device by ID, e.g. /dev/by-id/ata-xxxxx
	InstallationDisk string `json:"installationDisk"`

	// NetworkConfig is a YAML manifest that can be processed by nmstate, using
	// custom marshaling/unmarshaling that will allow to populate nmstate config
	// as plain yaml.
	// +optional
	NetworkConfig aiv1beta1.NetConfig `json:"networkConfig,omitempty"`

	// Proxy defines the proxy settings for the cluster.
	// If unset, the cluster will not be configured to use a proxy.
	// +optional
	Proxy *types.Proxy `json:"proxy,omitempty"`

	// PullSecret is the secret to use when pulling images.
	PullSecret string `json:"pullSecret"`

	// SeedImage is the seed image to use for the installation. This image will be
	// used to prepare the installation disk.
	SeedImage string `json:"seedImage"`

	// SeedVersion is the version of the seed image. It will be validated against
	// the seed image version.
	SeedVersion string `json:"seedVersion"`

	// Shutdown is a flag to shutdown the host after installation. It defaults to
	// false.
	// +optional
	Shutdown bool `json:"shutdown,omitempty"`

	// SkipDiskCleanup is a flag to skip disk cleanup before installation. As part
	// of installation we will try to format the disk this flag will skip that
	// step. It defaults to false.
	SkipDiskCleanup bool `json:"skipDiskCleanup,omitempty"`

	// SSHKey is the public Secure Shell (SSH) key to provide access to instances.
	SSHKey string `json:"sshKey,omitempty"`
}

InstallationConfig is the API for specifying configuration for the image-based installation ISO.

type KubeAPICrypto

type KubeAPICrypto struct {
	ServingCrypto ServingCrypto

	ClientAuthCrypto ClientAuthCrypto
}

KubeAPICrypto contains the kubernetes API private keys and certificates that are used to generate and sign the cluster's cryptographic objects.

type KubeConfigCryptoRetention

type KubeConfigCryptoRetention struct {
	KubeAPICrypto KubeAPICrypto

	IngresssCrypto IngresssCrypto
}

KubeConfigCryptoRetention contains all the crypto material that is required for the image-based installer to ensure that the kubeconfigs can be used to access the cluster after its configuration.

type SeedReconfiguration

type SeedReconfiguration struct {
	// AdditionalTrustBundle keeps the PEM-encoded x.509 certificate bundle(s)
	// that will be added to the nodes' trusted certificate store.
	AdditionalTrustBundle AdditionalTrustBundle `json:"additionalTrustBundle,omitempty"`

	// APIVersion is the version of this struct and it is used to detect breaking
	// changes.
	APIVersion int `json:"api_version"`

	// BaseDomain is the desired base domain.
	BaseDomain string `json:"base_domain,omitempty"`

	// ClusterID is the desired cluster ID.
	ClusterID string `json:"cluster_id,omitempty"`

	// ClusterName is the desired cluster name.
	ClusterName string `json:"cluster_name,omitempty"`

	// ChronyConfig is the desired chrony configuration and it is used to populate
	// the /etc/chrony.conf on the node.
	ChronyConfig string `json:"chrony_config,omitempty"`

	// Hostname is the desired hostname of the node.
	Hostname string `json:"hostname,omitempty"`

	// InfraID is the desired infra ID.
	InfraID string `json:"infra_id,omitempty"`

	// KubeadminPasswordHash is the hash of the password for the kubeadmin
	// user, as can be found in the kubeadmin key of the kube-system/kubeadmin
	// secret. This will replace the kubeadmin password of the seed cluster.
	KubeadminPasswordHash string `json:"kubeadmin_password_hash,omitempty"`

	// KubeconfigCryptoRetention contains all the crypto material that is required
	// for the image-based installer to ensure that the generated kubeconfigs can
	// be used to access the cluster after its configuration.
	KubeconfigCryptoRetention KubeConfigCryptoRetention

	// MachineNetwork is the list of IP address pools for machines.
	// This field replaces MachineCIDR, and if set MachineCIDR must
	// be empty or match the first entry in the list.
	// Default is 10.0.0.0/16 for all platforms other than Power VS.
	// For Power VS, the default is 192.168.0.0/24.
	MachineNetwork string `json:"machine_network,omitempty"`

	// NodeIP is the desired IP address of the node.
	NodeIP string `json:"node_ip,omitempty"`

	// RawNMStateConfig contains the nmstate configuration YAML manifest as string.
	// Example nmstate configurations can be found here: https://nmstate.io/examples.html.
	RawNMStateConfig string `json:"raw_nm_state_config,omitempty"`

	// RelaseRegistry is the container registry that hosts the release image of
	// the seed cluster.
	ReleaseRegistry string `json:"release_registry,omitempty"`

	// SSHKey is the public Secure Shell (SSH) key that provides access to the
	// node.
	SSHKey string `json:"ssh_key,omitempty"`

	// Proxy defines the proxy settings for the cluster.
	// If unset, the cluster will not be configured to use a proxy.
	Proxy *types.Proxy `json:"proxy,omitempty"`

	// PullSecret is the secret to use when pulling images.
	PullSecret string `json:"pull_secret,omitempty"`
}

SeedReconfiguration contains all the information that is required to transform a machine started from a single-node OpenShift (SNO) seed OCI image (which contains dummy seed configuration) into a SNO cluster with the desired configuration.

type ServingCrypto

type ServingCrypto struct {
	// LocalhostSignerPrivateKey is a PEM-encoded X.509 key.
	LocalhostSignerPrivateKey string `json:"localhost_signer_private_key,omitempty"`

	// ServiceNetworkSignerPrivateKey is a PEM-encoded X.509 key.
	ServiceNetworkSignerPrivateKey string `json:"service_network_signer_private_key,omitempty"`

	// LoadbalancerSignerPrivateKey is a PEM-encoded X.509 key.
	LoadbalancerSignerPrivateKey string `json:"loadbalancer_external_signer_private_key,omitempty"`
}

ServingCrypto contains the kubernetes API private keys that are used to generate the cluster's certificates.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL