summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJesse Pretorius <jesse.pretorius@rackspace.co.uk>2018-11-30 15:55:14 +0000
committerJesse Pretorius <jesse.pretorius@rackspace.co.uk>2018-11-30 15:55:14 +0000
commit455c2b44332f3c8891c09d19e24d73af3f1317b8 (patch)
tree44a16af6519afe85b5e8852aa4432ed8bb4e5096
parent851eeb5d49ebf4fc0058ec661fe48add15ac8508 (diff)
Enable overriding the service setup host python interpreter
In order to enable the service setup host python interpreter to be changed easily, we make it a variable. This will be useful when someone sets the service setup host to be the utility container, because we'll be able to set this var by default. Change-Id: Id8c2dfe7f3f82e0945d1b4b0027911a692cf1e8b
Notes
Notes (review): Code-Review+2: Marc GariƩpy (mgariepy) <gariepy.marc@gmail.com> Code-Review+2: Mohammed Naser <mnaser@vexxhost.com> Workflow+1: Mohammed Naser <mnaser@vexxhost.com> Verified+2: Zuul Submitted-by: Zuul Submitted-at: Fri, 30 Nov 2018 20:28:51 +0000 Reviewed-on: https://review.openstack.org/621192 Project: openstack/openstack-ansible-os_congress Branch: refs/heads/master
-rw-r--r--defaults/main.yml1
-rw-r--r--tasks/congress_service_setup.yml3
2 files changed, 2 insertions, 2 deletions
diff --git a/defaults/main.yml b/defaults/main.yml
index 03ea662..33eb09b 100644
--- a/defaults/main.yml
+++ b/defaults/main.yml
@@ -21,6 +21,7 @@ debug: False
21# for the service setup. The host must already have 21# for the service setup. The host must already have
22# clouds.yaml properly configured. 22# clouds.yaml properly configured.
23congress_service_setup_host: "{{ openstack_service_setup_host | default('localhost') }}" 23congress_service_setup_host: "{{ openstack_service_setup_host | default('localhost') }}"
24congress_service_setup_host_python_interpreter: "{{ openstack_service_setup_host_python_interpreter | default((congress_service_setup_host == 'localhost') | ternary(ansible_playbook_python, ansible_python['executable'])) }}"
24 25
25## Set the package install state for distribution packages 26## Set the package install state for distribution packages
26congress_pip_package_state: "latest" 27congress_pip_package_state: "latest"
diff --git a/tasks/congress_service_setup.yml b/tasks/congress_service_setup.yml
index d027e1f..7a2c33f 100644
--- a/tasks/congress_service_setup.yml
+++ b/tasks/congress_service_setup.yml
@@ -22,8 +22,7 @@
22- name: Setup the service 22- name: Setup the service
23 delegate_to: "{{ congress_service_setup_host }}" 23 delegate_to: "{{ congress_service_setup_host }}"
24 vars: 24 vars:
25 ansible_python_interpreter: >- 25 ansible_python_interpreter: "{{ congress_service_setup_host_python_interpreter }}"
26 {{ (congress_service_setup_host == 'localhost') | ternary(ansible_playbook_python, ansible_python['executable']) }}
27 block: 26 block:
28 - name: Add service to the keystone service catalog 27 - name: Add service to the keystone service catalog
29 os_keystone_service: 28 os_keystone_service: