acsengine

package
v0.25.1-rc.1 Latest Latest
Warning

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

Go to latest
Published: Nov 7, 2018 License: MIT Imports: 33 Imported by: 0

Documentation

Overview

Package acsengine takes an ACS cluster model and generates the corresponding template

Index

Constants

View Source
const (
	// DefaultVNETCIDR is the default CIDR block for the VNET
	DefaultVNETCIDR = "10.0.0.0/8"
	// DefaultInternalLbStaticIPOffset specifies the offset of the internal LoadBalancer's IP
	// address relative to the first consecutive Kubernetes static IP
	DefaultInternalLbStaticIPOffset = 10
	// NetworkPolicyNone is the string expression for the deprecated NetworkPolicy usage pattern "none"
	NetworkPolicyNone = "none"
	// NetworkPolicyCalico is the string expression for calico network policy config option
	NetworkPolicyCalico = "calico"
	// NetworkPolicyCilium is the string expression for cilium network policy config option
	NetworkPolicyCilium = "cilium"
	// NetworkPolicyAzure is the string expression for Azure CNI network policy manager
	NetworkPolicyAzure = "azure"
	// NetworkPluginAzure is the string expression for Azure CNI plugin
	NetworkPluginAzure = "azure"
	// NetworkPluginKubenet is the string expression for kubenet network plugin
	NetworkPluginKubenet = "kubenet"
	// NetworkPluginFlannel is the string expression for flannel network policy config option
	NetworkPluginFlannel = "flannel"
	// DefaultKubeHeapsterDeploymentAddonName is the name of the kube-heapster-deployment addon
	DefaultKubeHeapsterDeploymentAddonName = "kube-heapster-deployment"
	// DefaultKubeDNSDeploymentAddonName is the name of the kube-dns-deployment addon
	DefaultKubeDNSDeploymentAddonName = "kube-dns-deployment"
	// DefaultCoreDNSAddonName is the name of the coredns addon
	DefaultCoreDNSAddonName = "coredns"
	// DefaultDNSAutoscalerAddonName is the name of the coredns addon
	DefaultDNSAutoscalerAddonName = "dns-autoscaler"
	// DefaultKubeProxyAddonName is the name of the kube-proxy config addon
	DefaultKubeProxyAddonName = "kube-proxy-daemonset"
	// DefaultAzureStorageClassesAddonName is the name of the azure storage classes addon
	DefaultAzureStorageClassesAddonName = "azure-storage-classes"
	// DefaultAzureNpmDaemonSetAddonName is the name of the azure npm daemon set addon
	DefaultAzureNpmDaemonSetAddonName = "azure-npm-daemonset"
	// DefaultCalicoDaemonSetAddonName is the name of calico daemonset addon
	DefaultCalicoDaemonSetAddonName = "calico-daemonset"
	// DefaultCiliumDaemonSetAddonName is the name of cilium daemonset addon
	DefaultCiliumDaemonSetAddonName = "cilium-daemonset"
	// DefaultFlannelDaemonSetAddonName is the name of flannel plugin daemonset addon
	DefaultFlannelDaemonSetAddonName = "flannel-daemonset"
	// DefaultAADAdminGroupRBACAddonName is the name of the default admin group RBAC addon
	DefaultAADAdminGroupRBACAddonName = "aad-default-admin-group-rbac"
	// DefaultAzureCloudProviderDeploymentAddonName is the name of the azure cloud provider deployment addon
	DefaultAzureCloudProviderDeploymentAddonName = "azure-cloud-provider-deployment"
	// DefaultAzureCNINetworkMonitorAddonName is the name of the azure cni network monitor addon
	DefaultAzureCNINetworkMonitorAddonName = "azure-cni-networkmonitor"
	// DefaultAuditPolicyAddonName is the name of the audit policy addon
	DefaultAuditPolicyAddonName = "audit-policy"
	// DefaultTillerAddonName is the name of the tiller addon deployment
	DefaultTillerAddonName = "tiller"
	// DefaultTillerMaxHistory limits the maximum number of revisions saved per release. Use 0 for no limit.
	DefaultTillerMaxHistory = 0
	// DefaultAADPodIdentityAddonName is the name of the aad-pod-identity addon deployment
	DefaultAADPodIdentityAddonName = "aad-pod-identity"
	// DefaultACIConnectorAddonName is the name of the aci-connector addon deployment
	DefaultACIConnectorAddonName = "aci-connector"
	// DefaultDashboardAddonName is the name of the kubernetes-dashboard addon deployment
	DefaultDashboardAddonName = "kubernetes-dashboard"
	// DefaultClusterAutoscalerAddonName is the name of the autoscaler addon deployment
	DefaultClusterAutoscalerAddonName = "cluster-autoscaler"
	// DefaultBlobfuseFlexVolumeAddonName is the name of the blobfuse flexvolume addon
	DefaultBlobfuseFlexVolumeAddonName = "blobfuse-flexvolume"
	// DefaultSMBFlexVolumeAddonName is the name of the smb flexvolume addon
	DefaultSMBFlexVolumeAddonName = "smb-flexvolume"
	// DefaultKeyVaultFlexVolumeAddonName is the name of the keyvault flexvolume addon deployment
	DefaultKeyVaultFlexVolumeAddonName = "keyvault-flexvolume"
	// DefaultELBSVCAddonName is the name of the elb service addon deployment
	DefaultELBSVCAddonName = "elb-svc"
	// DefaultGeneratorCode specifies the source generator of the cluster template.
	DefaultGeneratorCode = "acsengine"
	// DefaultReschedulerAddonName is the name of the rescheduler addon deployment
	DefaultReschedulerAddonName = "rescheduler"
	// DefaultMetricsServerAddonName is the name of the kubernetes Metrics server addon deployment
	DefaultMetricsServerAddonName = "metrics-server"
	// NVIDIADevicePluginAddonName is the name of the kubernetes NVIDIA Device Plugin daemon set
	NVIDIADevicePluginAddonName = "nvidia-device-plugin"
	// ContainerMonitoringAddonName is the name of the kubernetes Container Monitoring addon deployment
	ContainerMonitoringAddonName = "container-monitoring"
	// AzureCNINetworkMonitoringAddonName is the name of the Azure CNI networkmonitor addon
	AzureCNINetworkMonitoringAddonName = "azure-cni-networkmonitor"
	// AzureNetworkPolicyAddonName is the name of the Azure CNI networkmonitor addon
	AzureNetworkPolicyAddonName = "azure-npm-daemonset"
	// IPMASQAgentAddonName is the name of the ip masq agent addon
	IPMASQAgentAddonName = "ip-masq-agent"
	// DefaultKubernetesKubeletMaxPods is the max pods per kubelet
	DefaultKubernetesKubeletMaxPods = 110
	// DefaultMasterEtcdServerPort is the default etcd server port for Kubernetes master nodes
	DefaultMasterEtcdServerPort = 2380
	// DefaultMasterEtcdClientPort is the default etcd client port for Kubernetes master nodes
	DefaultMasterEtcdClientPort = 2379
)
View Source
const (
	//DefaultExtensionsRootURL  Root URL for extensions
	DefaultExtensionsRootURL = "https://raw.githubusercontent.com/Azure/acs-engine/master/"
	// DefaultDockerEngineRepo for grabbing docker engine packages
	DefaultDockerEngineRepo = "https://download.docker.com/linux/ubuntu"
	// DefaultDockerComposeURL for grabbing docker images
	DefaultDockerComposeURL = "https://github.com/docker/compose/releases/download"
)
View Source
const (
	//DefaultConfigurationScriptRootURL  Root URL for configuration script (used for script extension on RHEL)
	DefaultConfigurationScriptRootURL = "https://raw.githubusercontent.com/Azure/acs-engine/master/parts/"
)

Variables

This section is empty.

Functions

func GenerateKubeConfig

func GenerateKubeConfig(properties *api.Properties, location string) (string, error)

GenerateKubeConfig returns a JSON string representing the KubeConfig

func GetTenantID

func GetTenantID(resourceManagerEndpoint string, subscriptionID string) (string, error)

GetTenantID figures out the AAD tenant ID of the subscription by making an unauthenticated request to the Get Subscription Details endpoint and parses the value from WWW-Authenticate header. TODO this should probably to to the armhelpers library

Types

type ArtifactWriter added in v0.5.0

type ArtifactWriter struct {
	Translator *i18n.Translator
}

ArtifactWriter represents the object that writes artifacts

func (*ArtifactWriter) WriteTLSArtifacts added in v0.5.0

func (w *ArtifactWriter) WriteTLSArtifacts(containerService *api.ContainerService, apiVersion, template, parameters, artifactsDir string, certsGenerated bool, parametersOnly bool) error

WriteTLSArtifacts saves TLS certificates and keys to the server filesystem

type AzureEndpointConfig added in v0.6.0

type AzureEndpointConfig struct {
	ResourceManagerVMDNSSuffix string
}

AzureEndpointConfig describes an Azure endpoint

type AzureOSImageConfig added in v0.6.0

type AzureOSImageConfig struct {
	ImageOffer     string
	ImageSku       string
	ImagePublisher string
	ImageVersion   string
}

AzureOSImageConfig describes an Azure OS image

type Context added in v0.5.0

type Context struct {
	Translator *i18n.Translator
}

Context represents the object that is passed to the package

type CustomFileReader added in v0.19.0

type CustomFileReader struct {
	Source io.Reader
	Dest   string
}

CustomFileReader takes represents the source text of a file as an io.Reader and the desired destination to add it to

type DCOSSpecConfig

type DCOSSpecConfig struct {
	DCOS188BootstrapDownloadURL     string
	DCOS190BootstrapDownloadURL     string
	DCOS198BootstrapDownloadURL     string
	DCOS110BootstrapDownloadURL     string
	DCOS111BootstrapDownloadURL     string
	DCOSWindowsBootstrapDownloadURL string
	DcosRepositoryURL               string // For custom install, for example CI, need these three addributes
	DcosClusterPackageListID        string // the id of the package list file
	DcosProviderPackageID           string // the id of the dcos-provider-xxx package
}

DCOSSpecConfig is the configurations of DCOS

type DockerSpecConfig

type DockerSpecConfig struct {
	DockerEngineRepo         string
	DockerComposeDownloadURL string
}

DockerSpecConfig is the configurations of docker

type KeyVaultID

type KeyVaultID struct {
	ID string `json:"id"`
}

KeyVaultID represents a KeyVault instance on Azure

type KeyVaultRef

type KeyVaultRef struct {
	KeyVault      KeyVaultID `json:"keyVault"`
	SecretName    string     `json:"secretName"`
	SecretVersion string     `json:"secretVersion,omitempty"`
}

KeyVaultRef represents a reference to KeyVault instance on Azure

type KubernetesSpecConfig

type KubernetesSpecConfig struct {
	KubernetesImageBase              string
	TillerImageBase                  string
	ACIConnectorImageBase            string
	NVIDIAImageBase                  string
	AzureCNIImageBase                string
	EtcdDownloadURLBase              string
	KubeBinariesSASURLBase           string
	WindowsTelemetryGUID             string
	CNIPluginsDownloadURL            string
	VnetCNILinuxPluginsDownloadURL   string
	VnetCNIWindowsPluginsDownloadURL string
	ContainerdDownloadURLBase        string
}

KubernetesSpecConfig is the kubernetes container images used.

type TemplateGenerator

type TemplateGenerator struct {
	Translator *i18n.Translator
}

TemplateGenerator represents the object that performs the template generation.

func InitializeTemplateGenerator

func InitializeTemplateGenerator(ctx Context) (*TemplateGenerator, error)

InitializeTemplateGenerator creates a new template generator object

func (*TemplateGenerator) GenerateTemplate

func (t *TemplateGenerator) GenerateTemplate(containerService *api.ContainerService, generatorCode string, acsengineVersion string) (templateRaw string, parametersRaw string, err error)

GenerateTemplate generates the template from the API Model

type V20160330ContainerService

type V20160330ContainerService struct {
	api.TypeMeta
	*v20160330.ContainerService
}

V20160330ContainerService is the type we read and write from file needed because the json that is sent to ARM and acs-engine is different from the json that the ACS RP Api gets from ARM

type VlabsContainerService

type VlabsContainerService struct {
	api.TypeMeta
	*vlabs.ContainerService
}

VlabsContainerService is the type we read and write from file needed because the json that is sent to ARM and acs-engine is different from the json that the ACS RP Api gets from ARM

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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