Add Helm 3.x support (#5441)
* Add Helm 3.x support * tiller enabled when helm < 3.0.0pull/5447/head
parent
f0f8379e1b
commit
db2ca014cb
|
@ -177,6 +177,10 @@ in the form of dicts of key-value pairs of configuration parameters that will be
|
|||
* *kube_kubeadm_controller_extra_args*
|
||||
* *kube_kubeadm_scheduler_extra_args*
|
||||
|
||||
## App variables
|
||||
|
||||
* *helm_version* - Defaults to v2.x, set to a v3 version (e.g. `v3.0.1` ) to install Helm 3.x (no more Tiller!). When changing this to 3 in an existing cluster, Tiller will be left alone and has to be removed manually.
|
||||
|
||||
## User accounts
|
||||
|
||||
By default, a user with admin rights is created, named `kube`.
|
||||
|
|
|
@ -364,7 +364,7 @@ test_image_repo: "{{ docker_image_repo }}/library/busybox"
|
|||
test_image_tag: latest
|
||||
busybox_image_repo: "{{ docker_image_repo }}/library/busybox"
|
||||
busybox_image_tag: 1.29.2
|
||||
helm_version: "v2.16.0"
|
||||
helm_version: "v2.16.1"
|
||||
helm_image_repo: "{{ docker_image_repo }}/lachlanevenson/k8s-helm"
|
||||
helm_image_tag: "{{ helm_version }}"
|
||||
tiller_image_repo: "{{ gcr_image_repo }}/kubernetes-helm/tiller"
|
||||
|
@ -793,7 +793,7 @@ downloads:
|
|||
- kube-node
|
||||
|
||||
tiller:
|
||||
enabled: "{{ helm_enabled }}"
|
||||
enabled: "{{ helm_enabled and helm_version is version('v3.0.0', '<') }}"
|
||||
container: true
|
||||
repo: "{{ tiller_image_repo }}"
|
||||
tag: "{{ tiller_image_tag }}"
|
||||
|
|
|
@ -17,6 +17,7 @@
|
|||
when:
|
||||
- dns_mode != 'none'
|
||||
- inventory_hostname == groups['kube-master'][0]
|
||||
- helm_version is version('v3.0.0', '<')
|
||||
|
||||
- name: Helm | Apply Helm Manifests (RBAC)
|
||||
kube:
|
||||
|
@ -30,11 +31,14 @@
|
|||
when:
|
||||
- dns_mode != 'none'
|
||||
- inventory_hostname == groups['kube-master'][0]
|
||||
- helm_version is version('v3.0.0', '<')
|
||||
|
||||
# Generate necessary certs for securing Helm and Tiller connection with TLS
|
||||
- name: Helm | Set up TLS
|
||||
include_tasks: "gen_helm_tiller_certs.yml"
|
||||
when: tiller_enable_tls
|
||||
when:
|
||||
- tiller_enable_tls
|
||||
- helm_version is version('v3.0.0', '<')
|
||||
|
||||
- name: Helm | Install client on all masters
|
||||
command: >
|
||||
|
@ -44,6 +48,8 @@
|
|||
--client-only
|
||||
environment: "{{ proxy_env }}"
|
||||
changed_when: false
|
||||
when:
|
||||
- helm_version is version('v3.0.0', '<')
|
||||
|
||||
# FIXME: https://github.com/helm/helm/issues/6374
|
||||
- name: Helm | Install/upgrade helm
|
||||
|
@ -67,6 +73,7 @@
|
|||
register: install_helm
|
||||
when:
|
||||
- inventory_hostname == groups['kube-master'][0]
|
||||
- helm_version is version('v3.0.0', '<')
|
||||
changed_when: false
|
||||
environment: "{{ proxy_env }}"
|
||||
|
||||
|
@ -91,6 +98,7 @@
|
|||
changed_when: false
|
||||
when:
|
||||
- inventory_hostname == groups['kube-master'][0]
|
||||
- helm_version is version('v3.0.0', '<')
|
||||
environment: "{{ proxy_env }}"
|
||||
|
||||
- name: Make sure bash_completion.d folder exists
|
||||
|
|
|
@ -8,3 +8,6 @@ container_manager: containerd
|
|||
etcd_deployment_type: host
|
||||
deploy_netchecker: true
|
||||
dns_min_replicas: 1
|
||||
|
||||
helm_enabled: true
|
||||
helm_version: v3.0.1
|
Loading…
Reference in New Issue