Documentation ¶
Overview ¶
Package cluster contains asset targets that generates the terraform file, prepare the infra, and bootstrap the cluster.
Index ¶
Constants ¶
const ( // GCPFirewallPermission is the role/permission to create or skip the creation of // firewall rules for GCP during a xpn installation. GCPFirewallPermission = "compute.firewalls.create" // TfVarsFileName is the filename for Terraform variables. TfVarsFileName = "terraform.tfvars.json" // TfPlatformVarsFileName is the name for platform-specific // Terraform variable files. // // https://www.terraform.io/docs/configuration/variables.html#variable-files TfPlatformVarsFileName = "terraform.platform.auto.tfvars.json" )
Variables ¶
var ( // InstallDir is the directory containing install assets. InstallDir string )
Functions ¶
func LoadMetadata ¶
func LoadMetadata(dir string) (*types.ClusterMetadata, error)
LoadMetadata loads the cluster metadata from an asset directory.
Types ¶
type Cluster ¶
Cluster uses the terraform executable to launch a cluster with the given terraform tfvar and generated templates.
func (*Cluster) Dependencies ¶
Dependencies returns the direct dependency for launching the cluster.
func (*Cluster) Generate ¶
Generate launches the cluster and generates the terraform state file on disk.
type Metadata ¶
Metadata contains information needed to destroy clusters.
func (*Metadata) Dependencies ¶
Dependencies returns the direct dependencies for the metadata asset.
type TerraformVariables ¶
TerraformVariables depends on InstallConfig, Manifests, and Ignition to generate the terrafor.tfvars.
func (*TerraformVariables) Dependencies ¶
func (t *TerraformVariables) Dependencies() []asset.Asset
Dependencies returns the dependency of the TerraformVariable
func (*TerraformVariables) Files ¶
func (t *TerraformVariables) Files() []*asset.File
Files returns the files generated by the asset.
func (*TerraformVariables) Generate ¶
func (t *TerraformVariables) Generate(parents asset.Parents) error
Generate generates the terraform.tfvars file.
func (*TerraformVariables) Load ¶
func (t *TerraformVariables) Load(f asset.FileFetcher) (found bool, err error)
Load reads the terraform.tfvars from disk.
func (*TerraformVariables) Name ¶
func (t *TerraformVariables) Name() string
Name returns the human-friendly name of the asset.