-
Notifications
You must be signed in to change notification settings - Fork 590
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refactor configuration defaults Add comments to config Add configurable utility images Add configurable network plugin images Add configurable kubedns images
- Loading branch information
Showing
19 changed files
with
278 additions
and
135 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
package cluster | ||
|
||
const ( | ||
DefaultClusterConfig = "cluster.yml" | ||
|
||
DefaultServiceClusterIPRange = "10.233.0.0/18" | ||
DefaultClusterCIDR = "10.233.64.0/18" | ||
DefaultClusterDNSService = "10.233.0.3" | ||
DefaultClusterDomain = "cluster.local" | ||
DefaultClusterSSHKeyPath = "~/.ssh/id_rsa" | ||
|
||
DefaultAuthStrategy = "x509" | ||
|
||
DefaultNetworkPlugin = "flannel" | ||
|
||
DefaultInfraContainerImage = "gcr.io/google_containers/pause-amd64:3.0" | ||
DefaultAplineImage = "alpine:latest" | ||
DefaultNginxProxyImage = "rancher/rke-nginx-proxy:0.1.0" | ||
DefaultCertDownloaderImage = "rancher/rke-cert-deployer:0.1.0" | ||
|
||
DefaultFlannelImage = "quay.io/coreos/flannel:v0.9.1" | ||
DefaultFlannelCNIImage = "quay.io/coreos/flannel-cni:v0.2.0" | ||
DefaultCalicoNodeImage = "quay.io/calico/node:v2.6.2" | ||
DefaultCalicoCNIImage = "quay.io/calico/cni:v1.11.0" | ||
DefaultCalicoControllersImage = "quay.io/calico/kube-controllers:v1.0.0" | ||
DefaultCanalNodeImage = "quay.io/calico/node:v2.6.2" | ||
DefaultCanalCNIImage = "quay.io/calico/cni:v1.11.0" | ||
DefaultCanalFlannelImage = "quay.io/coreos/flannel:v0.9.1" | ||
|
||
DefaultKubeDNSImage = "gcr.io/google_containers/k8s-dns-kube-dns-amd64:1.14.5" | ||
DefaultDNSMasqImage = "gcr.io/google_containers/k8s-dns-dnsmasq-nanny-amd64:1.14.5" | ||
DefaultKubeDNSSidecarImage = "gcr.io/google_containers/k8s-dns-sidecar-amd64:1.14.5" | ||
DefaultKubeDNSAutoScalerImage = "gcr.io/google_containers/cluster-proportional-autoscaler-amd64:1.0.0" | ||
) | ||
|
||
func setDefaultIfEmptyMapValue(configMap map[string]string, key string, value string) { | ||
if _, ok := configMap[key]; !ok { | ||
configMap[key] = value | ||
} | ||
} | ||
func setDefaultIfEmpty(varName *string, defaultValue string) { | ||
if len(*varName) == 0 { | ||
*varName = defaultValue | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.