Documentation ¶
Overview ¶
Copyright (C) 2021-2023, Kubefirst
This program is licensed under MIT. See the LICENSE file for more details.
Copyright (C) 2021-2023, Kubefirst ¶
This program is licensed under MIT. See the LICENSE file for more details.
Copyright (C) 2021-2023, Kubefirst ¶
This program is licensed under MIT. See the LICENSE file for more details.
Copyright (C) 2021-2023, Kubefirst ¶
This program is licensed under MIT. See the LICENSE file for more details.
Copyright (C) 2021-2023, Kubefirst ¶
This program is licensed under MIT. See the LICENSE file for more details.
Copyright (C) 2021-2023, Kubefirst ¶
This program is licensed under MIT. See the LICENSE file for more details.
Copyright (C) 2021-2023, Kubefirst ¶
This program is licensed under MIT. See the LICENSE file for more details.
Copyright (C) 2021-2023, Kubefirst ¶
This program is licensed under MIT. See the LICENSE file for more details.
Copyright (C) 2021-2023, Kubefirst ¶
This program is licensed under MIT. See the LICENSE file for more details.
Copyright (C) 2021-2023, Kubefirst ¶
This program is licensed under MIT. See the LICENSE file for more details.
Copyright (C) 2021-2023, Kubefirst ¶
This program is licensed under MIT. See the LICENSE file for more details.
Index ¶
- Constants
- func AdjustGitopsRepo(...) error
- func AdjustMetaphorRepo(destinationMetaphorRepoGitURL, gitopsRepoDir, gitProvider, k1Dir string) error
- func BootstrapVultrMgmtCluster(dryRun bool, kubeconfigPath string, gitProvider string, gitUser string) error
- func DetokenizeAdditionalPath(path string, tokens *GitOpsDirectoryValues) error
- func DetokenizeGitGitops(path string, tokens *GitOpsDirectoryValues) error
- func DetokenizeGitMetaphor(path string, tokens *MetaphorTokenValues) error
- func DownloadTools(...) error
- func GetDomainApexContent(domainName string) bool
- func GetGithubTerraformEnvs(envs map[string]string) map[string]string
- func GetGitlabTerraformEnvs(envs map[string]string, gid int) map[string]string
- func GetUsersTerraformEnvs(clientset *kubernetes.Clientset, config *VultrConfig, envs map[string]string) map[string]string
- func GetVaultTerraformEnvs(clientset *kubernetes.Clientset, config *VultrConfig, envs map[string]string) map[string]string
- func GetVultrTerraformEnvs(envs map[string]string) map[string]string
- func NewVultr() *govultr.Client
- func PrepareGitRepositories(gitProvider string, clusterName string, clusterType string, ...) error
- type GitOpsDirectoryValues
- type MetaphorTokenValues
- type VultrBucketCredentials
- type VultrConfig
- type VultrConfiguration
- func (c *VultrConfiguration) CreateObjectStorage(region string, storeName string) (govultr.ObjectStorage, error)
- func (c *VultrConfiguration) CreateObjectStorageBucket(cr VultrBucketCredentials, bucketName string) error
- func (c *VultrConfiguration) DeleteBlockStorage(blockStorage []govultr.BlockStorage) error
- func (c *VultrConfiguration) GetDNSInfo(domainName string) (string, error)
- func (c *VultrConfiguration) GetDNSRecords(domainName string) ([]govultr.DomainRecord, error)
- func (c *VultrConfiguration) GetKubernetesAssociatedBlockStorage(clusterName string, returnAll bool) ([]govultr.BlockStorage, error)
- func (c *VultrConfiguration) GetObjectStorage(region string) ([]govultr.ObjectStorage, error)
- func (c *VultrConfiguration) TestDomainLiveness(dryRun bool, domainName string) bool
Constants ¶
const ( CloudProvider = "vultr" GithubHost = "github.com" GitlabHost = "gitlab.com" KubectlClientVersion = "v1.25.7" LocalhostOS = runtime.GOOS LocalhostArch = runtime.GOARCH TerraformClientVersion = "1.3.8" ArgocdHelmChartVersion = "4.10.5" ArgocdPortForwardURL = pkg.ArgocdPortForwardURL VaultPortForwardURL = pkg.VaultPortForwardURL )
Variables ¶
This section is empty.
Functions ¶
func AdjustGitopsRepo ¶
func AdjustMetaphorRepo ¶
func DetokenizeAdditionalPath ¶
func DetokenizeAdditionalPath(path string, tokens *GitOpsDirectoryValues) error
DetokenizeAdditionalPath - Translate tokens by values on a given path
func DetokenizeGitGitops ¶
func DetokenizeGitGitops(path string, tokens *GitOpsDirectoryValues) error
DetokenizeGitGitops - Translate tokens by values on a given path
func DetokenizeGitMetaphor ¶
func DetokenizeGitMetaphor(path string, tokens *MetaphorTokenValues) error
DetokenizeGithubMetaphor - Translate tokens by values on a given path
func DownloadTools ¶
func GetDomainApexContent ¶
GetDomainApexContent determines whether or not a target domain features a host responding at zone apex
func GetGitlabTerraformEnvs ¶
func GetUsersTerraformEnvs ¶
func GetUsersTerraformEnvs(clientset *kubernetes.Clientset, config *VultrConfig, envs map[string]string) map[string]string
func GetVaultTerraformEnvs ¶
func GetVaultTerraformEnvs(clientset *kubernetes.Clientset, config *VultrConfig, envs map[string]string) map[string]string
func PrepareGitRepositories ¶
func PrepareGitRepositories( gitProvider string, clusterName string, clusterType string, destinationGitopsRepoGitURL string, gitopsDir string, gitopsTemplateBranch string, gitopsTemplateURL string, destinationMetaphorRepoGitURL string, k1Dir string, gitopsTokens *GitOpsDirectoryValues, metaphorDir string, metaphorTokens *MetaphorTokenValues, apexContentExists bool, ) error
Types ¶
type GitOpsDirectoryValues ¶
type GitOpsDirectoryValues struct { AlertsEmail string AtlantisAllowList string CloudProvider string CloudRegion string ClusterId string ClusterName string ClusterType string DomainName string KubeconfigPath string KubefirstStateStoreBucket string KubefirstTeam string KubefirstVersion string StateStoreBucketHostname string ArgoCDIngressURL string ArgoCDIngressNoHTTPSURL string ArgoWorkflowsIngressURL string ArgoWorkflowsIngressNoHTTPSURL string ArgoWorkflowsDir string AtlantisIngressURL string AtlantisIngressNoHTTPSURL string ChartMuseumIngressURL string VaultIngressURL string VaultIngressNoHTTPSURL string VouchIngressURL string GitDescription string GitNamespace string GitProvider string GitRunner string GitRunnerDescription string GitRunnerNS string GitURL string GitHubHost string GitHubOwner string GitHubUser string GitlabHost string GitlabOwner string GitlabOwnerGroupID int GitlabUser string GitOpsRepoAtlantisWebhookURL string GitOpsRepoGitURL string GitOpsRepoNoHTTPSURL string UseTelemetry string }
type MetaphorTokenValues ¶
type VultrBucketCredentials ¶
type VultrConfig ¶
type VultrConfig struct { VultrToken string `env:"VULTR_API_KEY"` GithubToken string `env:"GITHUB_TOKEN"` GitlabToken string `env:"GITLAB_TOKEN"` ArgoWorkflowsDir string DestinationGitopsRepoHttpsURL string DestinationGitopsRepoGitURL string DestinationMetaphorRepoHttpsURL string DestinationMetaphorRepoGitURL string GitopsDir string GitProvider string K1Dir string Kubeconfig string KubectlClient string KubefirstBotSSHPrivateKey string KubefirstConfig string LogsDir string MetaphorDir string RegistryAppName string RegistryYaml string SSLBackupDir string TerraformClient string ToolsDir string }
type VultrConfiguration ¶
var Conf VultrConfiguration = VultrConfiguration{ Client: NewVultr(), Context: context.Background(), }
func (*VultrConfiguration) CreateObjectStorage ¶
func (c *VultrConfiguration) CreateObjectStorage(region string, storeName string) (govultr.ObjectStorage, error)
CreateObjectStorage creates a Vultr object storage resource
func (*VultrConfiguration) CreateObjectStorageBucket ¶
func (c *VultrConfiguration) CreateObjectStorageBucket(cr VultrBucketCredentials, bucketName string) error
CreateObjectStorageBucket leverages minio to create a bucket within Vultr object storage
func (*VultrConfiguration) DeleteBlockStorage ¶
func (c *VultrConfiguration) DeleteBlockStorage(blockStorage []govultr.BlockStorage) error
DeleteBlockStorage iterates over target volumes and deletes them
func (*VultrConfiguration) GetDNSInfo ¶
func (c *VultrConfiguration) GetDNSInfo(domainName string) (string, error)
GetDNSInfo determines whether or not a domain exists within Vultr
func (*VultrConfiguration) GetDNSRecords ¶
func (c *VultrConfiguration) GetDNSRecords(domainName string) ([]govultr.DomainRecord, error)
GetStorageBuckets retrieves all Vultr object storage buckets
func (*VultrConfiguration) GetKubernetesAssociatedBlockStorage ¶
func (c *VultrConfiguration) GetKubernetesAssociatedBlockStorage(clusterName string, returnAll bool) ([]govultr.BlockStorage, error)
GetKubernetesAssociatedVolumes returns block storage associated with a Vultr Kubernetes cluster
func (*VultrConfiguration) GetObjectStorage ¶
func (c *VultrConfiguration) GetObjectStorage(region string) ([]govultr.ObjectStorage, error)
GetObjectStorage retrieves all Vultr object storage resources
func (*VultrConfiguration) TestDomainLiveness ¶
func (c *VultrConfiguration) TestDomainLiveness(dryRun bool, domainName string) bool