Skip to content

Commit

Permalink
salt: Upgrade orchestrate small improvement
Browse files Browse the repository at this point in the history
Do no longer provide `orchestrate.dest_version` pillar key to
`upgrade.precheck` as it do not use it, update `require_in` so that we
no longer run `Deploy Kubernetes service config objects` if one node
upgrade failed
  • Loading branch information
TeddyAndrieux committed Nov 13, 2020
1 parent a82c521 commit 45f2d0d
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions salt/metalk8s/orchestrate/upgrade/init.sls
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,6 @@ Execute the upgrade prechecks:
- mods:
- metalk8s.orchestrate.upgrade.precheck
- saltenv: {{ saltenv }}
- pillar:
orchestrate:
dest_version: {{ dest_version }}

{%- set cp_nodes = salt.metalk8s.minions_by_role('master') | sort %}
{%- set other_nodes = pillar.metalk8s.nodes.keys() | difference(cp_nodes) | sort %}
Expand Down Expand Up @@ -98,7 +95,7 @@ Deploy node {{ node }}:
- require:
- metalk8s_kubernetes: Set node {{ node }} version to {{ dest_version }}
- require_in:
- salt: Deploy Kubernetes objects
- salt: Deploy Kubernetes service config objects

{#- Ugly but needed since we have jinja2.7 (`loop.previtem` added in 2.10) #}
{%- set previous_node = node %}
Expand Down

0 comments on commit 45f2d0d

Please sign in to comment.