From f257e79affe93e4c5815b968bce3977ad4cf9b1c Mon Sep 17 00:00:00 2001 From: Michal Nasiadka Date: Tue, 22 Sep 2020 10:11:41 +0200 Subject: [PATCH] Allow setting container_proxy per service Currently there is no option to set container_proxy only for one service (e.g. magnum). This change adds this option. Change-Id: Ia938ee660ebe8ce84321f721b6292b0b58a06e20 --- ansible/roles/bifrost/defaults/main.yml | 2 ++ ansible/roles/bifrost/tasks/start.yml | 2 +- ansible/roles/glance/defaults/main.yml | 4 +++- ansible/roles/magnum/defaults/main.yml | 4 +++- 4 files changed, 9 insertions(+), 3 deletions(-) diff --git a/ansible/roles/bifrost/defaults/main.yml b/ansible/roles/bifrost/defaults/main.yml index 6be3d6cf83..7b171d65c2 100644 --- a/ansible/roles/bifrost/defaults/main.yml +++ b/ansible/roles/bifrost/defaults/main.yml @@ -10,3 +10,5 @@ bifrost_tag: "{{ openstack_tag }}" bifrost_deploy_image: "{{ docker_registry ~ '/' if docker_registry else '' }}{{ docker_namespace }}/{{ kolla_base_distro }}-{{ bifrost_install_type }}-bifrost-deploy" bifrost_deploy_tag: "{{ bifrost_tag }}" bifrost_deploy_image_full: "{{ bifrost_deploy_image }}:{{ bifrost_deploy_tag }}" + +bifrost_deploy_container_proxy: "{{ container_proxy }}" diff --git a/ansible/roles/bifrost/tasks/start.yml b/ansible/roles/bifrost/tasks/start.yml index c86e7c0d7a..2425c887c4 100644 --- a/ansible/roles/bifrost/tasks/start.yml +++ b/ansible/roles/bifrost/tasks/start.yml @@ -7,7 +7,7 @@ image: "{{ bifrost_deploy_image_full }}" name: "bifrost_deploy" privileged: True - environment: "{{ container_proxy }}" + environment: "{{ bifrost_deploy_container_proxy }}" volumes: - "{{ node_config_directory }}/bifrost/:/etc/bifrost:ro" - "/etc/localtime:/etc/localtime:ro" diff --git a/ansible/roles/glance/defaults/main.yml b/ansible/roles/glance/defaults/main.yml index 79765d37ed..e206870915 100644 --- a/ansible/roles/glance/defaults/main.yml +++ b/ansible/roles/glance/defaults/main.yml @@ -8,7 +8,7 @@ glance_services: host_in_groups: "{{ inventory_hostname in glance_api_hosts }}" enabled: true image: "{{ glance_api_image_full }}" - environment: "{{ container_proxy }}" + environment: "{{ glance_api_container_proxy }}" privileged: "{{ enable_cinder | bool and enable_cinder_backend_iscsi | bool }}" volumes: "{{ glance_api_default_volumes + glance_api_extra_volumes }}" dimensions: "{{ glance_api_dimensions }}" @@ -150,6 +150,8 @@ glance_extra_volumes: "{{ default_extra_volumes }}" glance_api_extra_volumes: "{{ glance_extra_volumes }}" glance_tls_proxy_extra_volumes: "{{ glance_extra_volumes }}" +glance_api_container_proxy: "{{ container_proxy }}" + #################### # Glance #################### diff --git a/ansible/roles/magnum/defaults/main.yml b/ansible/roles/magnum/defaults/main.yml index 414d676bac..da7ac8730f 100644 --- a/ansible/roles/magnum/defaults/main.yml +++ b/ansible/roles/magnum/defaults/main.yml @@ -27,7 +27,7 @@ magnum_services: group: magnum-conductor enabled: true image: "{{ magnum_conductor_image_full }}" - environment: "{{ container_proxy }}" + environment: "{{ magnum_conductor_container_proxy }}" volumes: "{{ magnum_conductor_default_volumes + magnum_conductor_extra_volumes }}" dimensions: "{{ magnum_conductor_dimensions }}" @@ -84,6 +84,8 @@ magnum_extra_volumes: "{{ default_extra_volumes }}" magnum_api_extra_volumes: "{{ magnum_extra_volumes }}" magnum_conductor_extra_volumes: "{{ magnum_extra_volumes }}" +magnum_conductor_container_proxy: "{{ container_proxy }}" + #################### # OpenStack ####################