Documentation
¶
Index ¶
- Variables
- func CreateSymLinks(sourceDir, targetDir string, overwriteSymlinks bool)
- func Download(fileName string, url string, mode os.FileMode)
- func EnableAndStartService(unitFile string) error
- func GetImages() []string
- func InitConfigurationFromFile(path string) (*apis.InitConfiguration, error)
- func InstallMasterComponents(config *apis.InitConfiguration)
- func InstallWorkerComponents(config *apis.JoinConfiguration)
- func JoinConfigurationFromFile(path string) (*apis.JoinConfiguration, error)
- func PlaceComponentsFromCache(netConfig apis.Networking)
- func PopulateCache()
- func ReplaceString(file string, from string, to string)
- func ResetFailedService(unitFile string) error
- func Run(rootDir string, cmdStr string, arg ...string)
- func RunBestEffort(rootDir string, cmdStr string, arg ...string)
- func StopAndDisableService(unitFile string) error
- type Artifact
Constants ¶
This section is empty.
Variables ¶
View Source
var DOCKER_IMAGES = []string{ constants.KEEPALIVED_IMG, fmt.Sprintf("k8s.gcr.io/kube-apiserver-amd64:%s", constants.KUBERNETES_VERSION), fmt.Sprintf("k8s.gcr.io/kube-controller-manager-amd64:%s", constants.KUBERNETES_VERSION), fmt.Sprintf("k8s.gcr.io/kube-scheduler-amd64:%s", constants.KUBERNETES_VERSION), fmt.Sprintf("k8s.gcr.io/kube-proxy-amd64:%s", constants.KUBERNETES_VERSION), fmt.Sprintf("k8s.gcr.io/k8s-dns-sidecar-amd64:%s", constants.KUBE_DNS_VERSION), fmt.Sprintf("k8s.gcr.io/k8s-dns-kube-dns-amd64:%s", constants.KUBE_DNS_VERSION), fmt.Sprintf("k8s.gcr.io/k8s-dns-dnsmasq-nanny-amd64:%s", constants.KUBE_DNS_VERSION), "quay.io/coreos/flannel:v0.10.0-amd64", "k8s.gcr.io/pause-amd64:3.1", "metallb/speaker:master", "metallb/controller:master", }
View Source
var NodeArtifact = []Artifact{ { Name: constants.KubeadmFilename, Type: "executable", Upstream: fmt.Sprintf("https://storage.googleapis.com/kubernetes-release/release/%s/bin/linux/amd64/", constants.KUBERNETES_VERSION), Local: filepath.Join(constants.CACHE_DIR, constants.KUBE_DIR_NAME), }, { Name: constants.KubectlFilename, Type: "executable", Upstream: fmt.Sprintf("https://storage.googleapis.com/kubernetes-release/release/%s/bin/linux/amd64/", constants.KUBERNETES_VERSION), Local: filepath.Join(constants.CACHE_DIR, constants.KUBE_DIR_NAME), }, { Name: constants.KubeletFilename, Type: "executable", Upstream: fmt.Sprintf("https://storage.googleapis.com/kubernetes-release/release/%s/bin/linux/amd64/", constants.KUBERNETES_VERSION), Local: filepath.Join(constants.CACHE_DIR, constants.KUBE_DIR_NAME), }, { Name: constants.KubeletSystemdUnitFilename, Type: "regular", Upstream: fmt.Sprintf("https://raw.githubusercontent.com/kubernetes/kubernetes/%s/build/debs/", constants.KUBERNETES_VERSION), Local: filepath.Join(constants.CACHE_DIR, constants.KUBE_DIR_NAME), }, { Name: constants.KubeadmKubeletSystemdDropinFilename, Type: "regular", Upstream: fmt.Sprintf("https://raw.githubusercontent.com/kubernetes/kubernetes/%s/build/debs/", constants.KUBERNETES_VERSION), Local: filepath.Join(constants.CACHE_DIR, constants.KUBE_DIR_NAME), }, { Name: constants.CNIPluginsFilename, Type: "regular", Upstream: fmt.Sprintf("https://github.com/containernetworking/plugins/releases/download/%s/", constants.CNI_VERSION), Local: filepath.Join(constants.CACHE_DIR, constants.CNI_DIR_NAME), }, { Name: constants.FlannelManifestFilename, Type: "regular", Upstream: fmt.Sprintf("https://raw.githubusercontent.com/coreos/flannel/%s/Documentation/", constants.FLANNEL_VERSION), Local: filepath.Join(constants.CACHE_DIR, constants.FLANNEL_DIR_NAME), }, }
Functions ¶
func CreateSymLinks ¶
Create symlinks of all the files inside sourceDir to targetDir
func EnableAndStartService ¶
EnableAndStartService enables and starts the etcd service
func InitConfigurationFromFile ¶
func InitConfigurationFromFile(path string) (*apis.InitConfiguration, error)
func InstallMasterComponents ¶
func InstallMasterComponents(config *apis.InitConfiguration)
func InstallWorkerComponents ¶
func InstallWorkerComponents(config *apis.JoinConfiguration)
func JoinConfigurationFromFile ¶
func JoinConfigurationFromFile(path string) (*apis.JoinConfiguration, error)
func PlaceComponentsFromCache ¶
func PlaceComponentsFromCache(netConfig apis.Networking)
func PopulateCache ¶
func PopulateCache()
func ReplaceString ¶
func ResetFailedService ¶
ResetFailedService invokes reset-failed on a service if the service satisfies the is-failed query, otherwise a noop
func RunBestEffort ¶
func StopAndDisableService ¶
StopAndDisableService stops and disables service
Types ¶
Click to show internal directories.
Click to hide internal directories.