1
0
mirror of https://github.com/rancher/types.git synced 2025-09-16 14:59:16 +00:00

Move k8s version defaults to types

This commit is contained in:
moelsayed
2018-02-19 17:58:37 +02:00
parent 02c6e2abe1
commit 2aaefed37f
2 changed files with 82 additions and 0 deletions

View File

@@ -0,0 +1,59 @@
package v3
var (
K8sVersionToRKESystemImages = map[string]RKESystemImages{
"v1.8.7-rancher1-1": v187SystemImages,
}
RancherK8sVersionToSystemImages = map[string]RancherSystemImages{
"v1.9.3-rancher1-1": v193SystemImages,
}
// v187SystemImages defaults for rke and rancher 2.0
v187SystemImages = RKESystemImages{
Etcd: "rancher/coreos-etcd:v3.0.17",
Kubernetes: "rancher/k8s:v1.8.7-rancher1-1",
Alpine: "alpine:latest",
NginxProxy: "rancher/rke-nginx-proxy:v0.1.1",
CertDownloader: "rancher/rke-cert-deployer:v0.1.1",
KubernetesServicesSidecar: "rancher/rke-service-sidekick:v0.1.0",
KubeDNS: "rancher/k8s-dns-kube-dns-amd64:1.14.5",
DNSmasq: "rancher/k8s-dns-dnsmasq-nanny-amd64:1.14.5",
KubeDNSSidecar: "rancher/k8s-dns-sidecar-amd64:1.14.5",
KubeDNSAutoscaler: "rancher/cluster-proportional-autoscaler-amd64:1.0.0",
Flannel: "rancher/coreos-flannel:v0.9.1",
FlannelCNI: "rancher/coreos-flannel-cni:v0.2.0",
CalicoNode: "rancher/calico-node:v2.6.2",
CalicoCNI: "rancher/calico-cni:v1.11.0",
CalicoControllers: "rancher/calico-kube-controllers:v1.0.0",
CalicoCtl: "rancher/calico-ctl:v1.6.2",
CanalNode: "rancher/calico-node:v2.6.2",
CanalCNI: "rancher/calico-cni:v1.11.0",
CanalFlannel: "rancher/coreos-flannel:v0.9.1",
WeaveNode: "weaveworks/weave-kube:2.1.2",
WeaveCNI: "weaveworks/weave-npc:2.1.2",
PodInfraContainer: "rancher/pause-amd64:3.0",
Ingress: "rancher/nginx-ingress-controller:0.10.2",
IngressBackend: "rancher/nginx-ingress-controller-defaultbackend:1.4",
}
// v193SystemImages defaults for 1.6 with k8s v1.9
v193SystemImages = RancherSystemImages{
RKESystemImages: RKESystemImages{
Etcd: "rancher/etcd:v2.3.7-13",
Kubernetes: "rancher/k8s:v1.9.3-rancher1-1",
KubeDNS: "rancher/k8s-dns-kube-dns-amd64:1.14.7",
DNSmasq: "rancher/k8s-dns-dnsmasq-nanny-amd64:1.14.7",
KubeDNSSidecar: "rancher/k8s-dns-sidecar-amd64:1.14.7",
Ingress: "rancher/lb-service-rancher:v0.7.17",
},
Kubectld: "rancher/kubectld:v0.8.6",
EtcHostUpdater: "rancher/etc-host-updater:v0.0.3",
K8sAgent: "rancher/kubernetes-agent:v0.6.6",
K8sAuth: "rancher/kubernetes-auth:v0.0.8",
Heapster: "rancher/heapster-grafana-amd64:v4.4.3",
Grafana: "rancher/heapster-amd64:v1.5.0",
Influxdb: "rancher/heapster-influxdb-amd64:v1.3.3",
Tiller: "rancher/tiller:v2.7.2",
}
)

View File

@@ -36,6 +36,29 @@ type PrivateRegistry struct {
Password string `yaml:"password" json:"password,omitempty"`
}
type RancherSystemImages struct {
// RKE system images
RKESystemImages `yaml:",inline" json:",inline"`
// Kubectld image
Kubectld string `yaml:"kubectld" json:"kubectld,omitempty"`
// Etc host updater image
EtcHostUpdater string `yaml:"etc_host_updater" json:"etcHostUpdater,omitempty"`
// Kubernetes agent image
K8sAgent string `yaml:"k8s_agent" json:"k8sAgent,omitempty"`
// Kubernetes auth service agent
K8sAuth string `yaml:"k8s_auth" json:"k8sAuth,omitempty"`
// Kubernetes Dashboard image
Dashboard string `yaml:"dashboard" json:"dashboard,omitempty"`
// Heapster addon image
Heapster string `yaml:"heapster" json:"heapster,omitempty"`
// Grafana image for heapster addon
Grafana string `yaml:"grafana" json:"grafana,omitempty"`
// Influxdb image for heapster addon
Influxdb string `yaml:"influxdb" json:"influxdb,omitempty"`
// Tiller addon image
Tiller string `yaml:"tiller" json:"tiller,omitempty"`
}
type RKESystemImages struct {
// etcd image
Etcd string `yaml:"etcd" json:"etcd,omitempty"`