mirror of
https://github.com/kubernetes-sigs/kubespray.git
synced 2026-02-28 09:39:12 +03:00
Calico upgrade path validation and old version cleanup (#6733)
* calico: add constant calico_min_version_required and verify current deployed version against it. * calico: remove upgrade support with data migration The tool was used pre v3.0.0 and is no longer needed. * calico: remove old version support from tasks * calico: remove old ver support from policy ctrl * calico: remove old ver support from node * canal: remove old ver support * remove unused calicoctl download checksums calico_min_version_required is the oldest version that can be installed Older versions can be removed.
This commit is contained in:
@@ -152,13 +152,13 @@
|
||||
|
||||
- name: Ensure minimum calico version
|
||||
assert:
|
||||
that: calico_version is version('v3.0.0', '>=')
|
||||
msg: "calico_version is too low. Minimum version v3.0.0"
|
||||
that: calico_version is version(calico_min_version_required, '>=')
|
||||
msg: "calico_version is too low. Minimum version {{ calico_min_version_required }}"
|
||||
run_once: yes
|
||||
when:
|
||||
- kube_network_plugin == 'calico'
|
||||
|
||||
- name: "Get current version of calico cluster version"
|
||||
- name: Get current calico cluster version
|
||||
shell: "set -o pipefail && {{ bin_dir }}/calicoctl.sh version | grep 'Cluster Version:' | awk '{ print $3}'"
|
||||
args:
|
||||
executable: /bin/bash
|
||||
@@ -171,11 +171,11 @@
|
||||
when:
|
||||
- kube_network_plugin == 'calico'
|
||||
|
||||
- name: "Check that calico version is enough for upgrade"
|
||||
- name: Check that current calico version is enough for upgrade
|
||||
assert:
|
||||
that:
|
||||
- calico_version_on_server.stdout is version('v2.6.5', '>=')
|
||||
msg: "Your version of calico is not fresh enough for upgrade. Minimum version v2.6.5"
|
||||
- calico_version_on_server.stdout is version(calico_min_version_required, '>=')
|
||||
msg: "Your version of calico is not fresh enough for upgrade. Minimum version {{ calico_min_version_required }}"
|
||||
when:
|
||||
- kube_network_plugin == 'calico'
|
||||
- 'calico_version_on_server.stdout is defined'
|
||||
|
||||
Reference in New Issue
Block a user