client

package
v10.1.1+incompatible Latest Latest
Warning

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

Go to latest
Published: Oct 24, 2019 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func EnsureResourceGroup

func EnsureResourceGroup(log *logrus.Entry, conf *Config) error

EnsureResourceGroup creates a resource group and returns whether the resource group was actually created or not and any error encountered.

func GenerateManifest

func GenerateManifest(conf *Config, i interface{}) error

GenerateManifest accepts a manifest file and returns a OSA struct of the type requested by the caller. If the provided manifest is templatized, it will be parsed appropriately.

func WriteClusterConfigToManifest

func WriteClusterConfigToManifest(oc interface{}, manifestFile string) error

WriteClusterConfigToManifest write to file

Types

type Config

type Config struct {
	SubscriptionID      string `envconfig:"AZURE_SUBSCRIPTION_ID" required:"true"`
	TenantID            string `envconfig:"AZURE_TENANT_ID" required:"true"`
	ClientID            string `envconfig:"AZURE_CLIENT_ID" required:"true"`
	ClientSecret        string `envconfig:"AZURE_CLIENT_SECRET" required:"true"`
	AADClientID         string `envconfig:"AZURE_AAD_CLIENT_ID"`
	AADClientSecret     string `envconfig:"AZURE_AAD_CLIENT_SECRET"`
	AADGroupAdminsID    string `envconfig:"AZURE_AAD_GROUP_ADMINS_ID"`
	DeployVersion       string `envconfig:"DEPLOY_VERSION" required:"true"`
	RunningUnderTest    string `envconfig:"RUNNING_UNDER_TEST"`
	WorkspaceResourceID string `envconfig:"AZURE_WORKSPACE_ID"`
	PrivateAPIServer    bool   `envconfig:"PRIVATE_API_SERVER"`

	ManagementResourceGroup string
	Region                  string `envconfig:"AZURE_REGION" required:"false"`
	Regions                 string `envconfig:"AZURE_REGIONS" required:"true"`
	ResourceGroup           string `envconfig:"RESOURCEGROUP" required:"true"`

	DNSDomain        string `envconfig:"DNS_DOMAIN" required:"true"`
	DNSResourceGroup string `envconfig:"DNS_RESOURCEGROUP" required:"true"`

	ResourceGroupTTL string `envconfig:"RESOURCEGROUP_TTL"`
	Manifest         string `envconfig:"MANIFEST"`
	NoWait           bool   `envconfig:"NO_WAIT"`
}

func NewClientConfig

func NewClientConfig(log *logrus.Entry) (*Config, error)

NewClientConfig returns instance of Config for client

func NewServerConfig

func NewServerConfig(log *logrus.Entry, cs *api.OpenShiftManagedCluster) (*Config, error)

NewServerConfig returns instance of Config for server

Jump to

Keyboard shortcuts

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