Add support for k8s v1.16.0-beta.2 (#5148)

Cleaned up deprecated APIs:
apps/v1beta1
apps/v1beta2
extensions/v1beta1 for ds,deploy,rs

Add workaround for deploying helm using incompatible
deployment manifest.
Change-Id: I78b36741348f47a999df3841ee63cf4e6f377830
This commit is contained in:
Matthew Mosesohn
2019-09-10 22:06:55 +03:00
committed by Kubernetes Prow Robot
parent 637f09f140
commit 27ec548b88
31 changed files with 84 additions and 51 deletions

View File

@@ -36,8 +36,9 @@
include_tasks: "gen_helm_tiller_certs.yml"
when: tiller_enable_tls
# FIXME: https://github.com/helm/helm/issues/6374
- name: Helm | Install/upgrade helm
command: >
shell: >
{{ bin_dir }}/helm init --tiller-namespace={{ tiller_namespace }}
{% if helm_skip_refresh %} --skip-refresh{% endif %}
{% if helm_stable_repo_url is defined %} --stable-repo-url {{ helm_stable_repo_url }}{% endif %}
@@ -51,6 +52,10 @@
{% if tiller_enable_tls %} --tiller-tls --tiller-tls-verify --tiller-tls-cert={{ tiller_tls_cert }} --tiller-tls-key={{ tiller_tls_key }} --tls-ca-cert={{ tiller_tls_ca_cert }} {% endif %}
{% if tiller_secure_release_info %} --override 'spec.template.spec.containers[0].command'='{/tiller,--storage=secret}' {% endif %}
{% if tiller_wait %} --wait{% endif %}
--output yaml
| sed 's@apiVersion: extensions/v1beta1@apiVersion: apps/v1@'
| {{ bin_dir }}/kubectl patch --local -oyaml -f - -p '{"spec":{"selector": {"app":"helm","name":"tiller"} } }'
| {{ bin_dir }}/kubectl apply -f -
{% else %}
--client-only
{% endif %}
@@ -73,6 +78,8 @@
{% if tiller_secure_release_info %} --override 'spec.template.spec.containers[0].command'='{/tiller,--storage=secret}' {% endif %}
{% if tiller_wait %} --wait{% endif %}
--output yaml
| sed 's@apiVersion: extensions/v1beta1@apiVersion: apps/v1@'
| {{ bin_dir }}/kubectl patch --local -oyaml -f - -p '{"spec":{"selector": {"app":"helm","name":"tiller"} } }'
| {{ bin_dir }}/kubectl apply -f -
changed_when: false
when: