Add heat param for openshift prerequisites playbook

Previously the path to the openshift-ansible's prerequisites playbook
was hardcoded to
/usr/share/ansible/openshift-ansible/playbooks/prerequisites.yml. This
commit introduces the `OpenShiftPrerequisitesPlaybook` heat parameter
to make it configurable.

Also add more explicit description for the other playbook path
parameters and update the default path for OpenShiftUpgradePlaybook
that was broken since the move to openshift-ansible 3.10.

Change-Id: I2260cb8b0cef9650c707d4db917a3281a697912d
This commit is contained in:
Martin André 2018-09-21 14:11:52 +02:00
parent 6adc2f3f85
commit 46246e8745

View File

@ -41,18 +41,22 @@ parameters:
type: json
OpenShiftAnsiblePlaybook:
default: '/usr/share/ansible/openshift-ansible/playbooks/deploy_cluster.yml'
description: Path to OpenShift-Ansible playbook.
description: Path to OpenShift-Ansible deploy playbook.
type: string
OpenShiftPrerequisitesPlaybook:
default: '/usr/share/ansible/openshift-ansible/playbooks/prerequisites.yml'
description: Path to OpenShift-Ansible prerequisites playbook.
type: string
OpenShiftMasterScaleupPlaybook:
default: '/usr/share/ansible/openshift-ansible/playbooks/openshift-master/scaleup.yml'
description: Path to OpenShift-Ansible playbook.
description: Path to OpenShift-Ansible master scale-up playbook.
type: string
OpenShiftWorkerScaleupPlaybook:
default: '/usr/share/ansible/openshift-ansible/playbooks/openshift-node/scaleup.yml'
description: Path to OpenShift-Ansible playbook.
description: Path to OpenShift-Ansible node scale-up playbook.
type: string
OpenShiftUpgradePlaybook:
default: '/usr/share/ansible/openshift-ansible/playbooks/byo/openshift-cluster/upgrades/v3_9/upgrade.yml'
default: '/usr/share/ansible/openshift-ansible/playbooks/byo/openshift-cluster/upgrades/v3_10/upgrade.yml'
description: Path to OpenShift-Ansible Upgrade playbook.
type: string
OpenShiftGlobalVariables:
@ -276,6 +280,7 @@ outputs:
- name: set openshift ansible playbook paths
set_fact:
openshift_ansible_playbook_path: {get_param: OpenShiftAnsiblePlaybook}
openshift_prerequisites_playbook_path: {get_param: OpenShiftPrerequisitesPlaybook}
openshift_master_scaleup_playbook_path: {get_param: OpenShiftMasterScaleupPlaybook}
openshift_worker_scaleup_playbook_path: {get_param: OpenShiftWorkerScaleupPlaybook}
openshift_upgrade_playbook_path: {get_param: OpenShiftUpgradePlaybook}
@ -326,7 +331,8 @@ outputs:
enabled: yes
- include: "/usr/share/ansible/openshift-ansible/playbooks/prerequisites.yml"
- include: "{{openshift_prerequisites_playbook_path}}"
{% if tripleo_stack_action == 'UPDATE' and new_masters | count > 0 %}
- include: "{{openshift_master_scaleup_playbook_path}}"
{% endif %}