Documentation ¶
Index ¶
- func ParseInput(path string) (*api.VlabsARMContainerService, error)
- func ParseOutput(path string) (*api.ContainerService, error)
- type Config
- type Engine
- func (e *Engine) Generate() error
- func (e *Engine) HasAddon(name string) (bool, api.KubernetesAddon)
- func (e *Engine) HasGPUNodes() bool
- func (e *Engine) HasLinuxAgents() bool
- func (e *Engine) HasWindowsAgents() bool
- func (e *Engine) NodeCount() int
- func (e *Engine) OrchestratorVersion1Dot8AndUp() bool
- func (e *Engine) Write() error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ParseInput ¶ added in v0.13.0
func ParseInput(path string) (*api.VlabsARMContainerService, error)
ParseInput takes a template path and will parse that into a api.VlabsARMContainerService
func ParseOutput ¶ added in v0.13.0
func ParseOutput(path string) (*api.ContainerService, error)
ParseOutput takes the generated api model and will parse that into a api.ContainerService
Types ¶
type Config ¶
type Config struct { ClientID string `envconfig:"CLIENT_ID"` ClientSecret string `envconfig:"CLIENT_SECRET"` MasterDNSPrefix string `envconfig:"DNS_PREFIX"` AgentDNSPrefix string `envconfig:"DNS_PREFIX"` PublicSSHKey string `envconfig:"PUBLIC_SSH_KEY"` WindowsAdminPasssword string `envconfig:"WINDOWS_ADMIN_PASSWORD"` OrchestratorRelease string `envconfig:"ORCHESTRATOR_RELEASE"` OrchestratorVersion string `envconfig:"ORCHESTRATOR_VERSION"` OutputDirectory string `envconfig:"OUTPUT_DIR" default:"_output"` CreateVNET bool `envconfig:"CREATE_VNET" default:"false"` ClusterDefinitionPath string // The original template we want to use to build the cluster from. ClusterDefinitionTemplate string // This is the template after we splice in the environment variables GeneratedDefinitionPath string // Holds the contents of running acs-engine generate OutputPath string // This is the root output path DefinitionName string // Unique cluster name GeneratedTemplatePath string // azuredeploy.json path GeneratedParametersPath string // azuredeploy.parameters.json path }
Config represents the configuration values of a template stored as env vars
func ParseConfig ¶
ParseConfig will return a new engine config struct taking values from env vars
type Engine ¶
type Engine struct { Config *Config ClusterDefinition *api.VlabsARMContainerService // Holds the parsed ClusterDefinition ExpandedDefinition *api.ContainerService // Holds the expanded ClusterDefinition }
Engine holds necessary information to interact with acs-engine cli
func Build ¶
Build takes a template path and will inject values based on provided environment variables it will then serialize the structs back into json and save it to outputPath
func (*Engine) HasAddon ¶ added in v0.14.0
func (e *Engine) HasAddon(name string) (bool, api.KubernetesAddon)
HasAddon will return true if an addon is enabled
func (*Engine) HasGPUNodes ¶ added in v0.14.0
HasGPUNodes will return true if the VM SKU is GPU-enabled
func (*Engine) HasLinuxAgents ¶
HasLinuxAgents will return true if there is at least 1 linux agent pool
func (*Engine) HasWindowsAgents ¶
HasWindowsAgents will return true is there is at least 1 windows agent pool
func (*Engine) NodeCount ¶
NodeCount returns the number of nodes that should be provisioned for a given cluster definition
func (*Engine) OrchestratorVersion1Dot8AndUp ¶ added in v0.10.0
OrchestratorVersion1Dot8AndUp will return true if the orchestrator version is 1.8 and up