From cf1de90684a14f9bd194d10a69210f9cb7e5abb2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Andr=C3=A9?= Date: Mon, 12 Feb 2018 11:02:30 +0100 Subject: [PATCH] Allow passing custom openshift-ansible playbook This allows deploying openshift from the packaged openshift-ansible or from a git checkout more easily, by setting the OpenShiftAnsiblePlaybook heat environment variable. Change-Id: I60594faa10dfd817d94038b3938d7de269330e2e --- extraconfig/services/openshift-master.yaml | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/extraconfig/services/openshift-master.yaml b/extraconfig/services/openshift-master.yaml index f8f9744b97..6c8ba644cd 100644 --- a/extraconfig/services/openshift-master.yaml +++ b/extraconfig/services/openshift-master.yaml @@ -37,6 +37,10 @@ parameters: default: {} description: Global Ansible variables for OpenShift-Ansible installer. type: json + OpenShiftAnsiblePlaybook: + default: '/usr/share/ansible/openshift-ansible/playbooks/byo/config.yml' + description: Path to OpenShift-Ansible playbook. + type: string outputs: role_data: @@ -117,6 +121,10 @@ outputs: dest: "{{playbook_dir}}/openshift/global_vars.yml" content: "{{openshift_global_vars|to_nice_yaml}}" + - name: set openshift ansible playbook path + set_fact: + openshift_ansible_playbook_path: {get_param: OpenShiftAnsiblePlaybook} + - name: generate openshift playbook copy: dest: "{{playbook_dir}}/openshift/playbook.yml" @@ -163,7 +171,7 @@ outputs: state: restarted enabled: yes - - include: /usr/share/ansible/openshift-ansible/playbooks/byo/config.yml + - include: "{{openshift_ansible_playbook_path}}" - name: set openshift command set_fact: openshift_command: >-