Documentation
¶
Index ¶
- Constants
- func ConvertSpotBoolToVMProvisioningType(spot bool) string
- type Client
- func (client *Client) ConfigExists() (bool, error)
- func (client *Client) DeleteAll(config ConfigView) error
- func (client *Client) EnsureBucketExists() error
- func (client *Client) HasAsset(filename string) (bool, error)
- func (client *Client) Load() (Config, error)
- func (client *Client) LoadAsset(filename string) ([]byte, error)
- func (client *Client) NewConfig() Config
- func (client *Client) StoreAsset(filename string, contents []byte) error
- func (client *Client) Update(config Config) error
- type Config
- func (c Config) GetAllowIPs() string
- func (c Config) GetAllowIPsUnformatted() string
- func (c Config) GetAvailabilityZone() string
- func (c Config) GetBitbucketClientID() string
- func (c Config) GetBitbucketClientSecret() string
- func (c Config) GetConcourseCACert() string
- func (c Config) GetConcourseCert() string
- func (c Config) GetConcourseKey() string
- func (c Config) GetConcoursePassword() string
- func (c Config) GetConcourseUsername() string
- func (c Config) GetConcourseWebSize() string
- func (c Config) GetConcourseWorkerCount() int
- func (c Config) GetConcourseWorkerSize() string
- func (c Config) GetConfigBucket() string
- func (c Config) GetCredhubAdminClientSecret() string
- func (c Config) GetCredhubCACert() string
- func (c Config) GetCredhubPassword() string
- func (c Config) GetCredhubURL() string
- func (c Config) GetCredhubUsername() string
- func (c Config) GetDeployment() string
- func (c Config) GetDirectorCACert() string
- func (c Config) GetDirectorCert() string
- func (c Config) GetDirectorHMUserPassword() string
- func (c Config) GetDirectorKey() string
- func (c Config) GetDirectorMbusPassword() string
- func (c Config) GetDirectorNATSPassword() string
- func (c Config) GetDirectorPassword() string
- func (c Config) GetDirectorPublicIP() string
- func (c Config) GetDirectorRegistryPassword() string
- func (c Config) GetDirectorUsername() string
- func (c Config) GetDomain() string
- func (c Config) GetEnableGlobalResources() bool
- func (c Config) GetEnablePipelineInstances() bool
- func (c Config) GetEncryptionKey() string
- func (c Config) GetGithubCaCert() string
- func (c Config) GetGithubClientID() string
- func (c Config) GetGithubClientSecret() string
- func (c Config) GetGithubHost() string
- func (c Config) GetGrafanaPassword() string
- func (c Config) GetHostedZoneID() string
- func (c Config) GetHostedZoneRecordPrefix() string
- func (c Config) GetIAAS() string
- func (c Config) GetInfluxDbRetention() string
- func (c Config) GetMainGithubOrgs() string
- func (c Config) GetMainGithubTeams() string
- func (c Config) GetMainGithubUsers() string
- func (c Config) GetMicrosoftClientID() string
- func (c Config) GetMicrosoftClientSecret() string
- func (c Config) GetMicrosoftTenant() string
- func (c Config) GetNamespace() string
- func (c Config) GetNetworkCIDR() string
- func (c Config) GetPersistentDiskSize() string
- func (c Config) GetPrivateCIDR() string
- func (c Config) GetPrivateKey() string
- func (c Config) GetProject() string
- func (c Config) GetPublicCIDR() string
- func (c Config) GetPublicKey() string
- func (c Config) GetRDS1CIDR() string
- func (c Config) GetRDS2CIDR() string
- func (c Config) GetRDSDefaultDatabaseName() string
- func (c Config) GetRDSDiskEncryption() bool
- func (c Config) GetRDSInstanceClass() string
- func (c Config) GetRDSPassword() string
- func (c Config) GetRDSUsername() string
- func (c Config) GetRegion() string
- func (c Config) GetSourceAccessIP() string
- func (c Config) GetTFStatePath() string
- func (c Config) GetTags() []string
- func (c Config) GetVersion() string
- func (c Config) GetWorkerType() string
- func (c Config) IsBitbucketAuthSet() bool
- func (c Config) IsGithubAuthSet() bool
- func (c Config) IsGithubEnterpriseAuthSet() bool
- func (c Config) IsMainGithubAuthSet() bool
- func (c Config) IsMicrosoftAuthSet() bool
- func (c Config) IsSpot() bool
- func (c Config) MetricsIsDisabled() bool
- type ConfigView
- type IClient
Constants ¶
View Source
const ON_DEMAND = "on-demand"
View Source
const SPOT = "spot"
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Client ¶
type Client struct { Iaas iaas.Provider Project string Namespace string BucketName string BucketExists bool BucketError error }
Client is a client for loading the config file from S3
func (*Client) ConfigExists ¶
ConfigExists returns true if the configuration file exists
func (*Client) DeleteAll ¶
func (client *Client) DeleteAll(config ConfigView) error
DeleteAll deletes the entire configuration bucket
func (*Client) EnsureBucketExists ¶
func (*Client) StoreAsset ¶
StoreAsset stores an associated configuration file
type Config ¶
type Config struct { AllowIPs string `json:"allow_ips"` AllowIPsUnformatted string `json:"allow_ips_unformatted"` AvailabilityZone string `json:"availability_zone"` BitbucketClientID string `json:"bitbucket_client_id"` BitbucketClientSecret string `json:"bitbucket_client_secret"` ConcourseCACert string `json:"concourse_ca_cert"` ConcourseCert string `json:"concourse_cert"` ConcourseKey string `json:"concourse_key"` ConcoursePassword string `json:"concourse_password"` ConcourseUsername string `json:"concourse_username"` ConcourseWebSize string `json:"concourse_web_size"` ConcourseWorkerCount int `json:"concourse_worker_count"` ConcourseWorkerSize string `json:"concourse_worker_size"` ConfigBucket string `json:"config_bucket"` CredhubAdminClientSecret string `json:"credhub_admin_client_secret"` CredhubCACert string `json:"credhub_ca_cert"` CredhubPassword string `json:"credhub_password"` CredhubURL string `json:"credhub_url"` CredhubUsername string `json:"credhub_username"` Deployment string `json:"deployment"` DirectorCACert string `json:"director_ca_cert"` DirectorCert string `json:"director_cert"` DirectorHMUserPassword string `json:"director_hm_user_password"` DirectorKey string `json:"director_key"` DirectorMbusPassword string `json:"director_mbus_password"` DirectorNATSPassword string `json:"director_nats_password"` DirectorPassword string `json:"director_password"` DirectorPublicIP string `json:"director_public_ip"` DirectorRegistryPassword string `json:"director_registry_password"` DirectorUsername string `json:"director_username"` Domain string `json:"domain"` EnableGlobalResources bool `json:"enable_global_resources"` EnablePipelineInstances bool `json:"enable_pipeline_instances"` InfluxDbRetention string `json:"influx_db_retention_period"` EncryptionKey string `json:"encryption_key"` GithubClientID string `json:"github_client_id"` GithubClientSecret string `json:"github_client_secret"` GithubHost string `json:"github_host"` GithubCaCert string `json:"github_ca_cert"` GrafanaPassword string `json:"grafana_password"` HostedZoneID string `json:"hosted_zone_id"` HostedZoneRecordPrefix string `json:"hosted_zone_record_prefix"` IAAS string `json:"iaas"` MainGithubUsers string `json:"main_github_users"` MainGithubTeams string `json:"main_github_teams"` MainGithubOrgs string `json:"main_github_orgs"` MicrosoftClientID string `json:"microsoft_client_id"` MicrosoftClientSecret string `json:"microsoft_client_secret"` MicrosoftTenant string `json:"microsoft_tenant"` Namespace string `json:"namespace"` NetworkCIDR string `json:"network_cidr"` NoMetrics bool `json:"no_metrics"` PersistentDisk string `json:"persistent_disk"` PrivateCIDR string `json:"private_cidr"` PrivateKey string `json:"private_key"` Project string `json:"project"` PublicCIDR string `json:"public_cidr"` PublicKey string `json:"public_key"` RDS1CIDR string `json:"rds1_cidr"` RDS2CIDR string `json:"rds2_cidr"` RDSDefaultDatabaseName string `json:"rds_default_database_name"` RDSInstanceClass string `json:"rds_instance_class"` RDSPassword string `json:"rds_password"` RDSUsername string `json:"rds_username"` RDSDiskEncryption bool `json:"rds_disk_encryption"` Region string `json:"region"` SourceAccessIP string `json:"source_access_ip"` //Spot is deprecated, exists only as we need to migrate old configs to VMProvisioningType Spot bool `json:"spot"` Tags []string `json:"tags"` TFStatePath string `json:"tf_state_path"` Version string `json:"version"` VMProvisioningType string `json:"vm_provisioning_type"` WorkerType string `json:"worker_type"` }
Config represents a control-tower configuration file
func (Config) GetAllowIPs ¶
func (Config) GetAllowIPsUnformatted ¶
func (Config) GetAvailabilityZone ¶
func (Config) GetBitbucketClientID ¶
func (Config) GetBitbucketClientSecret ¶
func (Config) GetConcourseCACert ¶
func (Config) GetConcourseCert ¶
func (Config) GetConcourseKey ¶
func (Config) GetConcoursePassword ¶
func (Config) GetConcourseUsername ¶
func (Config) GetConcourseWebSize ¶
func (Config) GetConcourseWorkerCount ¶
func (Config) GetConcourseWorkerSize ¶
func (Config) GetConfigBucket ¶
func (Config) GetCredhubAdminClientSecret ¶
func (Config) GetCredhubCACert ¶
func (Config) GetCredhubPassword ¶
func (Config) GetCredhubURL ¶
func (Config) GetCredhubUsername ¶
func (Config) GetDeployment ¶
func (Config) GetDirectorCACert ¶
func (Config) GetDirectorCert ¶
func (Config) GetDirectorHMUserPassword ¶
func (Config) GetDirectorKey ¶
func (Config) GetDirectorMbusPassword ¶
func (Config) GetDirectorNATSPassword ¶
func (Config) GetDirectorPassword ¶
func (Config) GetDirectorPublicIP ¶
func (Config) GetDirectorRegistryPassword ¶
func (Config) GetDirectorUsername ¶
func (Config) GetEnableGlobalResources ¶
func (Config) GetEnablePipelineInstances ¶
func (Config) GetEncryptionKey ¶
func (Config) GetGithubCaCert ¶
func (Config) GetGithubClientID ¶
func (Config) GetGithubClientSecret ¶
func (Config) GetGithubHost ¶
func (Config) GetGrafanaPassword ¶
func (Config) GetHostedZoneID ¶
func (Config) GetHostedZoneRecordPrefix ¶
func (Config) GetInfluxDbRetention ¶
func (Config) GetMainGithubOrgs ¶
func (Config) GetMainGithubTeams ¶
func (Config) GetMainGithubUsers ¶
func (Config) GetMicrosoftClientID ¶
func (Config) GetMicrosoftClientSecret ¶
func (Config) GetMicrosoftTenant ¶
func (Config) GetNamespace ¶
func (Config) GetNetworkCIDR ¶
func (Config) GetPersistentDiskSize ¶
func (Config) GetPrivateCIDR ¶
func (Config) GetPrivateKey ¶
func (Config) GetProject ¶
func (Config) GetPublicCIDR ¶
func (Config) GetPublicKey ¶
func (Config) GetRDS1CIDR ¶
func (Config) GetRDS2CIDR ¶
func (Config) GetRDSDefaultDatabaseName ¶
func (Config) GetRDSDiskEncryption ¶
func (Config) GetRDSInstanceClass ¶
func (Config) GetRDSPassword ¶
func (Config) GetRDSUsername ¶
func (Config) GetSourceAccessIP ¶
func (Config) GetTFStatePath ¶
func (Config) GetVersion ¶
func (Config) GetWorkerType ¶
func (Config) IsBitbucketAuthSet ¶
func (Config) IsGithubAuthSet ¶
func (Config) IsGithubEnterpriseAuthSet ¶
func (Config) IsMainGithubAuthSet ¶
func (Config) IsMicrosoftAuthSet ¶
func (Config) MetricsIsDisabled ¶
type ConfigView ¶
type ConfigView interface { GetAllowIPs() string GetAllowIPsUnformatted() string GetAvailabilityZone() string GetBitbucketClientID() string GetBitbucketClientSecret() string GetConcourseCACert() string GetConcourseCert() string GetConcourseKey() string GetConcoursePassword() string GetConcourseUsername() string GetConcourseWebSize() string GetConcourseWorkerCount() int GetConcourseWorkerSize() string GetConfigBucket() string GetCredhubAdminClientSecret() string GetCredhubCACert() string GetCredhubPassword() string GetCredhubURL() string GetCredhubUsername() string GetDeployment() string GetDirectorCACert() string GetDirectorCert() string GetDirectorHMUserPassword() string GetDirectorKey() string GetDirectorMbusPassword() string GetDirectorNATSPassword() string GetDirectorPassword() string GetDirectorPublicIP() string GetDirectorRegistryPassword() string GetDirectorUsername() string GetDomain() string GetEnableGlobalResources() bool GetEnablePipelineInstances() bool GetInfluxDbRetention() string GetEncryptionKey() string GetGithubClientID() string GetGithubClientSecret() string GetGithubHost() string GetGithubCaCert() string GetGrafanaPassword() string GetHostedZoneID() string GetHostedZoneRecordPrefix() string GetIAAS() string GetMainGithubUsers() string GetMainGithubTeams() string GetMainGithubOrgs() string GetMicrosoftClientID() string GetMicrosoftClientSecret() string GetMicrosoftTenant() string GetNamespace() string GetNetworkCIDR() string GetPersistentDiskSize() string GetPrivateCIDR() string GetPrivateKey() string GetProject() string GetPublicCIDR() string GetPublicKey() string GetRDS1CIDR() string GetRDS2CIDR() string GetRDSDefaultDatabaseName() string GetRDSInstanceClass() string GetRDSPassword() string GetRDSUsername() string GetRDSDiskEncryption() bool GetRegion() string GetSourceAccessIP() string GetTags() []string GetTFStatePath() string GetVersion() string GetWorkerType() string IsBitbucketAuthSet() bool IsGithubAuthSet() bool IsGithubEnterpriseAuthSet() bool IsMainGithubAuthSet() bool IsMicrosoftAuthSet() bool IsSpot() bool MetricsIsDisabled() bool }
type IClient ¶
type IClient interface { Load() (Config, error) DeleteAll(config ConfigView) error Update(Config) error StoreAsset(filename string, contents []byte) error HasAsset(filename string) (bool, error) ConfigExists() (bool, error) LoadAsset(filename string) ([]byte, error) NewConfig() Config EnsureBucketExists() error }
counterfeiter: generate . IClient
Click to show internal directories.
Click to hide internal directories.