Merge "Fix Trident playbook"

This commit is contained in:
Zuul 2021-09-27 12:02:44 +00:00 committed by Gerrit Code Review
commit 79490cfa1b
2 changed files with 18 additions and 0 deletions

View File

@ -13,6 +13,7 @@
# Main play
roles:
- { role: common/prepare-env }
- { role: common/get-kube-version, become: yes }
- { role: roles/common/push-docker-images, become: yes }
- { role: roles/k8s-storage-backends/snapshot-controller, become: yes }
- { role: roles/k8s-storage-backends/netapp, become: yes }

View File

@ -0,0 +1,17 @@
---
#
# Copyright (c) 2021 Wind River Systems, Inc.
#
# SPDX-License-Identifier: Apache-2.0
#
- block:
- name: Get kubernetes_version from the DB
shell: echo "select kubeadm_version from kube_cmd_versions" | psql -qAt -d sysinv
register: kube_ver_select_result
become_user: postgres
- name: Set kubernetes_version to the value from DB
set_fact:
kubernetes_version: "{{ kube_ver_select_result.stdout_lines[0] }}"
when: kubernetes_version is not defined