From b540717387b1c6776524686cbc96f3ecfbebd599 Mon Sep 17 00:00:00 2001 From: Marcin Juszkiewicz Date: Fri, 8 Apr 2022 16:52:14 +0200 Subject: [PATCH] drop qdrouterd support Change-Id: I562fa187094f212003d0b17d20675f771cf082e6 --- ansible/group_vars/all.yml | 8 --- ansible/inventory/all-in-one | 3 - ansible/inventory/multinode | 3 - ansible/roles/qdrouterd/defaults/main.yml | 41 ------------ ansible/roles/qdrouterd/handlers/main.yml | 16 ----- .../roles/qdrouterd/tasks/add_sasl_user.yml | 19 ------ .../qdrouterd/tasks/check-containers.yml | 17 ----- ansible/roles/qdrouterd/tasks/check.yml | 1 - ansible/roles/qdrouterd/tasks/config.yml | 62 ------------------- .../qdrouterd/tasks/deploy-containers.yml | 2 - ansible/roles/qdrouterd/tasks/deploy.yml | 9 --- ansible/roles/qdrouterd/tasks/main.yml | 2 - ansible/roles/qdrouterd/tasks/precheck.yml | 39 ------------ ansible/roles/qdrouterd/tasks/pull.yml | 3 - ansible/roles/qdrouterd/tasks/reconfigure.yml | 2 - ansible/roles/qdrouterd/tasks/stop.yml | 6 -- ansible/roles/qdrouterd/tasks/upgrade.yml | 7 --- .../templates/qdrouterd-sasl.conf.j2 | 4 -- .../qdrouterd/templates/qdrouterd.conf.j2 | 58 ----------------- .../qdrouterd/templates/qdrouterd.json.j2 | 29 --------- ansible/roles/qdrouterd/vars/main.yml | 2 - ansible/site.yml | 12 ---- etc/kolla/globals.yml | 10 --- etc/kolla/passwords.yml | 5 -- tests/templates/inventory.j2 | 3 - 25 files changed, 363 deletions(-) delete mode 100644 ansible/roles/qdrouterd/defaults/main.yml delete mode 100644 ansible/roles/qdrouterd/handlers/main.yml delete mode 100644 ansible/roles/qdrouterd/tasks/add_sasl_user.yml delete mode 100644 ansible/roles/qdrouterd/tasks/check-containers.yml delete mode 100644 ansible/roles/qdrouterd/tasks/check.yml delete mode 100644 ansible/roles/qdrouterd/tasks/config.yml delete mode 100644 ansible/roles/qdrouterd/tasks/deploy-containers.yml delete mode 100644 ansible/roles/qdrouterd/tasks/deploy.yml delete mode 100644 ansible/roles/qdrouterd/tasks/main.yml delete mode 100644 ansible/roles/qdrouterd/tasks/precheck.yml delete mode 100644 ansible/roles/qdrouterd/tasks/pull.yml delete mode 100644 ansible/roles/qdrouterd/tasks/reconfigure.yml delete mode 100644 ansible/roles/qdrouterd/tasks/stop.yml delete mode 100644 ansible/roles/qdrouterd/tasks/upgrade.yml delete mode 100644 ansible/roles/qdrouterd/templates/qdrouterd-sasl.conf.j2 delete mode 100644 ansible/roles/qdrouterd/templates/qdrouterd.conf.j2 delete mode 100644 ansible/roles/qdrouterd/templates/qdrouterd.json.j2 delete mode 100644 ansible/roles/qdrouterd/vars/main.yml diff --git a/ansible/group_vars/all.yml b/ansible/group_vars/all.yml index 7c650dd11d..4cc833802c 100644 --- a/ansible/group_vars/all.yml +++ b/ansible/group_vars/all.yml @@ -469,8 +469,6 @@ prometheus_elasticsearch_exporter_port: "9108" # Prometheus blackbox-exporter ports prometheus_blackbox_exporter_port: "9115" -qdrouterd_port: "31459" - rabbitmq_port: "{{ '5671' if rabbitmq_enable_tls | bool else '5672' }}" rabbitmq_management_port: "15672" rabbitmq_cluster_port: "25672" @@ -700,7 +698,6 @@ enable_ovs_dpdk: "no" enable_osprofiler: "no" enable_placement: "{{ enable_nova | bool or enable_zun | bool }}" enable_prometheus: "no" -enable_qdrouterd: "{{ 'yes' if om_rpc_transport == 'amqp' else 'no' }}" enable_redis: "no" enable_sahara: "no" enable_senlin: "no" @@ -808,11 +805,6 @@ rabbitmq_enable_tls: "no" # CA certificate bundle in RabbitMQ container. rabbitmq_cacert: "/etc/ssl/certs/{{ 'ca-certificates.crt' if kolla_base_distro in ['debian', 'ubuntu'] else 'ca-bundle.trust.crt' }}" -#################### -# Qdrouterd options -#################### -qdrouterd_user: "openstack" - #################### # HAProxy options #################### diff --git a/ansible/inventory/all-in-one b/ansible/inventory/all-in-one index f7aa2101ae..733b493d7a 100644 --- a/ansible/inventory/all-in-one +++ b/ansible/inventory/all-in-one @@ -77,9 +77,6 @@ control [outward-rabbitmq:children] control -[qdrouterd:children] -control - [monasca-agent:children] compute control diff --git a/ansible/inventory/multinode b/ansible/inventory/multinode index 04dfe199c2..15b86d5c82 100644 --- a/ansible/inventory/multinode +++ b/ansible/inventory/multinode @@ -101,9 +101,6 @@ control [outward-rabbitmq:children] control -[qdrouterd:children] -control - [monasca-agent:children] compute control diff --git a/ansible/roles/qdrouterd/defaults/main.yml b/ansible/roles/qdrouterd/defaults/main.yml deleted file mode 100644 index 5121242927..0000000000 --- a/ansible/roles/qdrouterd/defaults/main.yml +++ /dev/null @@ -1,41 +0,0 @@ ---- -qdrouterd_services: - qdrouterd: - container_name: qdrouterd - group: qdrouterd - enabled: true - image: "{{ qdrouterd_image_full }}" - volumes: "{{ qdrouterd_default_volumes + qdrouterd_extra_volumes }}" - dimensions: "{{ qdrouterd_dimensions }}" - healthcheck: "{{ qdrouterd_healthcheck }}" - - -#################### -# Docker -#################### -qdrouterd_install_type: "{{ kolla_install_type }}" -qdrouterd_image: "{{ docker_registry ~ '/' if docker_registry else '' }}{{ docker_namespace }}/{{ kolla_base_distro }}-{{ qdrouterd_install_type }}-qdrouterd" -qdrouterd_tag: "{{ openstack_tag }}" -qdrouterd_image_full: "{{ qdrouterd_image }}:{{ qdrouterd_tag }}" -qdrouterd_dimensions: "{{ default_container_dimensions }}" - -qdrouterd_enable_healthchecks: "{{ enable_container_healthchecks }}" -qdrouterd_healthcheck_interval: "{{ default_container_healthcheck_interval }}" -qdrouterd_healthcheck_retries: "{{ default_container_healthcheck_retries }}" -qdrouterd_healthcheck_start_period: "{{ default_container_healthcheck_start_period }}" -qdrouterd_healthcheck_test: ["CMD-SHELL", "healthcheck_curl http://{{ api_interface_address | put_address_in_context('url') }}:{{ qdrouterd_port }}"] -qdrouterd_healthcheck_timeout: "{{ default_container_healthcheck_timeout }}" -qdrouterd_healthcheck: - interval: "{{ qdrouterd_healthcheck_interval }}" - retries: "{{ qdrouterd_healthcheck_retries }}" - start_period: "{{ qdrouterd_healthcheck_start_period }}" - test: "{% if qdrouterd_enable_healthchecks | bool %}{{ qdrouterd_healthcheck_test }}{% else %}NONE{% endif %}" - timeout: "{{ qdrouterd_healthcheck_timeout }}" - -qdrouterd_default_volumes: - - "{{ node_config_directory }}/qdrouterd/:{{ container_config_directory }}/:ro" - - "/etc/localtime:/etc/localtime:ro" - - "{{ '/etc/timezone:/etc/timezone:ro' if ansible_facts.os_family == 'Debian' else '' }}" - - "qdrouterd:/var/lib/qdrouterd/" - - "kolla_logs:/var/log/kolla/" -qdrouterd_extra_volumes: "{{ default_extra_volumes }}" diff --git a/ansible/roles/qdrouterd/handlers/main.yml b/ansible/roles/qdrouterd/handlers/main.yml deleted file mode 100644 index 729f221632..0000000000 --- a/ansible/roles/qdrouterd/handlers/main.yml +++ /dev/null @@ -1,16 +0,0 @@ ---- -- name: Restart qdrouterd container - vars: - service_name: "qdrouterd" - service: "{{ qdrouterd_services[service_name] }}" - become: true - kolla_docker: - action: "recreate_or_restart_container" - common_options: "{{ docker_common_options }}" - name: "{{ service.container_name }}" - image: "{{ service.image }}" - volumes: "{{ service.volumes }}" - dimensions: "{{ service.dimensions }}" - healthcheck: "{{ service.healthcheck | default(omit) }}" - when: - - kolla_action != "config" diff --git a/ansible/roles/qdrouterd/tasks/add_sasl_user.yml b/ansible/roles/qdrouterd/tasks/add_sasl_user.yml deleted file mode 100644 index da938c29a7..0000000000 --- a/ansible/roles/qdrouterd/tasks/add_sasl_user.yml +++ /dev/null @@ -1,19 +0,0 @@ ---- -- name: Wait for qdrouterd is up - wait_for: - host: "{{ api_interface_address }}" - port: "{{ qdrouterd_port }}" - connect_timeout: 1 - state: started - when: - - kolla_action != "config" - -- name: Create qdrouterd sasl user - shell: > - set -o pipefail && \ - echo {{ qdrouterd_password }} | \ - docker exec -u root -i qdrouterd saslpasswd2 -c -p -f /var/lib/qdrouterd/qdrouterd.sasldb -u AMQP {{ qdrouterd_user }} - run_once: true - changed_when: true - when: - - kolla_action != "config" diff --git a/ansible/roles/qdrouterd/tasks/check-containers.yml b/ansible/roles/qdrouterd/tasks/check-containers.yml deleted file mode 100644 index 5d713c1c33..0000000000 --- a/ansible/roles/qdrouterd/tasks/check-containers.yml +++ /dev/null @@ -1,17 +0,0 @@ ---- -- name: Check qdrouterd containers - become: true - kolla_docker: - action: "compare_container" - common_options: "{{ docker_common_options }}" - name: "{{ item.value.container_name }}" - image: "{{ item.value.image }}" - volumes: "{{ item.value.volumes }}" - dimensions: "{{ item.value.dimensions }}" - healthcheck: "{{ item.value.healthcheck | default(omit) }}" - when: - - inventory_hostname in groups[item.value.group] - - item.value.enabled | bool - with_dict: "{{ qdrouterd_services }}" - notify: - - "Restart {{ item.key }} container" diff --git a/ansible/roles/qdrouterd/tasks/check.yml b/ansible/roles/qdrouterd/tasks/check.yml deleted file mode 100644 index ed97d539c0..0000000000 --- a/ansible/roles/qdrouterd/tasks/check.yml +++ /dev/null @@ -1 +0,0 @@ ---- diff --git a/ansible/roles/qdrouterd/tasks/config.yml b/ansible/roles/qdrouterd/tasks/config.yml deleted file mode 100644 index ff426f1204..0000000000 --- a/ansible/roles/qdrouterd/tasks/config.yml +++ /dev/null @@ -1,62 +0,0 @@ ---- -- name: Ensuring config directories exist - file: - path: "{{ node_config_directory }}/{{ item.key }}" - state: "directory" - owner: "{{ config_owner_user }}" - group: "{{ config_owner_group }}" - mode: "0770" - become: true - when: - - inventory_hostname in groups[item.value.group] - - item.value.enabled | bool - with_dict: "{{ qdrouterd_services }}" - -- name: Copying over config.json files for services - template: - src: "{{ item.key }}.json.j2" - dest: "{{ node_config_directory }}/{{ item.key }}/config.json" - mode: "0660" - become: true - when: - - inventory_hostname in groups[item.value.group] - - item.value.enabled | bool - with_dict: "{{ qdrouterd_services }}" - notify: - - Restart qdrouterd container - -- name: Copying over qdrouterd config - vars: - service: "{{ qdrouterd_services['qdrouterd'] }}" - template: - src: "{{ item }}" - dest: "{{ node_config_directory }}/qdrouterd/qdrouterd.conf" - mode: "0660" - become: true - when: - - inventory_hostname in groups[service.group] - - service.enabled | bool - with_first_found: - - "{{ node_custom_config }}/qdrouterd/{{ inventory_hostname }}/qdrouterd.conf" - - "{{ node_custom_config }}/qdrouterd/qdrouterd.conf" - - "qdrouterd.conf.j2" - notify: - - Restart qdrouterd container - -- name: Copying over qdrouterd sasl config - vars: - service: "{{ qdrouterd_services['qdrouterd'] }}" - template: - src: "{{ item }}" - dest: "{{ node_config_directory }}/qdrouterd/qdrouterd-sasl.conf" - mode: "0660" - become: true - when: - - inventory_hostname in groups[service.group] - - service.enabled | bool - with_first_found: - - "{{ node_custom_config }}/qdrouterd/{{ inventory_hostname }}/qdrouterd-sasl.conf" - - "{{ node_custom_config }}/qdrouterd/qdrouterd-sasl.conf" - - "qdrouterd-sasl.conf.j2" - notify: - - Restart qdrouterd container diff --git a/ansible/roles/qdrouterd/tasks/deploy-containers.yml b/ansible/roles/qdrouterd/tasks/deploy-containers.yml deleted file mode 100644 index eb24ab5c7a..0000000000 --- a/ansible/roles/qdrouterd/tasks/deploy-containers.yml +++ /dev/null @@ -1,2 +0,0 @@ ---- -- import_tasks: check-containers.yml diff --git a/ansible/roles/qdrouterd/tasks/deploy.yml b/ansible/roles/qdrouterd/tasks/deploy.yml deleted file mode 100644 index 5b19eeab6a..0000000000 --- a/ansible/roles/qdrouterd/tasks/deploy.yml +++ /dev/null @@ -1,9 +0,0 @@ ---- -- import_tasks: config.yml - -- import_tasks: check-containers.yml - -- name: Flush handlers - meta: flush_handlers - -- import_tasks: add_sasl_user.yml diff --git a/ansible/roles/qdrouterd/tasks/main.yml b/ansible/roles/qdrouterd/tasks/main.yml deleted file mode 100644 index bc5d1e6257..0000000000 --- a/ansible/roles/qdrouterd/tasks/main.yml +++ /dev/null @@ -1,2 +0,0 @@ ---- -- include_tasks: "{{ kolla_action }}.yml" diff --git a/ansible/roles/qdrouterd/tasks/precheck.yml b/ansible/roles/qdrouterd/tasks/precheck.yml deleted file mode 100644 index 53f98d6bcf..0000000000 --- a/ansible/roles/qdrouterd/tasks/precheck.yml +++ /dev/null @@ -1,39 +0,0 @@ ---- -- import_role: - name: service-precheck - vars: - service_precheck_services: "{{ qdrouterd_services }}" - service_name: "{{ project_name }}" - -- name: Get container facts - become: true - kolla_container_facts: - name: - - qdrouterd - register: container_facts - -- name: Checking free port for Qdrouterd - wait_for: - host: "{{ api_interface_address }}" - port: "{{ qdrouterd_port }}" - connect_timeout: 1 - timeout: 1 - state: stopped - when: - - container_facts['qdrouterd'] is not defined - - inventory_hostname in groups['qdrouterd'] - -- name: Check if all qdrouterd hostnames are resolvable - vars: - nss_database: "{{ 'ahostsv4' if api_address_family == 'ipv4' else 'ahostsv6' }}" - command: "getent {{ nss_database }} {{ hostvars[item].ansible_facts.hostname }}" - changed_when: false - register: qdrouterd_hostnames - with_items: "{{ groups['qdrouterd'] }}" - -- name: Check if hostname resolves to IP address of api_interface - fail: - msg: "Hostname has to resolve to IP address of api_interface" - with_items: "{{ qdrouterd_hostnames.results }}" - when: - - "item.stdout.find('api' | kolla_address(item['item'])) == -1" diff --git a/ansible/roles/qdrouterd/tasks/pull.yml b/ansible/roles/qdrouterd/tasks/pull.yml deleted file mode 100644 index 53f9c5fda1..0000000000 --- a/ansible/roles/qdrouterd/tasks/pull.yml +++ /dev/null @@ -1,3 +0,0 @@ ---- -- import_role: - role: service-images-pull diff --git a/ansible/roles/qdrouterd/tasks/reconfigure.yml b/ansible/roles/qdrouterd/tasks/reconfigure.yml deleted file mode 100644 index 5b10a7e111..0000000000 --- a/ansible/roles/qdrouterd/tasks/reconfigure.yml +++ /dev/null @@ -1,2 +0,0 @@ ---- -- import_tasks: deploy.yml diff --git a/ansible/roles/qdrouterd/tasks/stop.yml b/ansible/roles/qdrouterd/tasks/stop.yml deleted file mode 100644 index 06338ec17e..0000000000 --- a/ansible/roles/qdrouterd/tasks/stop.yml +++ /dev/null @@ -1,6 +0,0 @@ ---- -- import_role: - name: service-stop - vars: - project_services: "{{ qdrouterd_services }}" - service_name: "{{ project_name }}" diff --git a/ansible/roles/qdrouterd/tasks/upgrade.yml b/ansible/roles/qdrouterd/tasks/upgrade.yml deleted file mode 100644 index 49edff81e3..0000000000 --- a/ansible/roles/qdrouterd/tasks/upgrade.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- -- import_tasks: config.yml - -- import_tasks: check-containers.yml - -- name: Flush handlers - meta: flush_handlers diff --git a/ansible/roles/qdrouterd/templates/qdrouterd-sasl.conf.j2 b/ansible/roles/qdrouterd/templates/qdrouterd-sasl.conf.j2 deleted file mode 100644 index bf213635ff..0000000000 --- a/ansible/roles/qdrouterd/templates/qdrouterd-sasl.conf.j2 +++ /dev/null @@ -1,4 +0,0 @@ -pwcheck_method: auxprop -auxprop_plugin: sasldb -sasldb_path: /var/lib/qdrouterd/qdrouterd.sasldb -mech_list: ANONYMOUS PLAIN diff --git a/ansible/roles/qdrouterd/templates/qdrouterd.conf.j2 b/ansible/roles/qdrouterd/templates/qdrouterd.conf.j2 deleted file mode 100644 index 7d13584fbc..0000000000 --- a/ansible/roles/qdrouterd/templates/qdrouterd.conf.j2 +++ /dev/null @@ -1,58 +0,0 @@ - -router { - mode: standalone - id: Router.A - workerThreads: 4 - saslConfigPath: /etc/sasl2 - saslConfigName: qdrouterd -} - -listener { - host: {{ api_interface_address }} - port: {{ qdrouterd_port }} - role: normal - authenticatePeer: no -} - -address { - prefix: unicast - distribution: closest -} -address { - prefix: exclusive - distribution: closest -} -address { - prefix: broadcast - distribution: multicast -} -address { - prefix: openstack.org/om/rpc/multicast - distribution: multicast -} -address { - prefix: openstack.org/om/rpc/unicast - distribution: closest -} -address { - prefix: openstack.org/om/rpc/anycast - distribution: balanced -} -address { - prefix: openstack.org/om/notify/multicast - distribution: multicast -} -address { - prefix: openstack.org/om/notify/unicast - distribution: closest -} -address { - prefix: openstack.org/om/notify/anycast - distribution: balanced -} - -log { - module: DEFAULT - enable: info+ - output: /var/log/kolla/qdrouterd/qdrouterd.log -} diff --git a/ansible/roles/qdrouterd/templates/qdrouterd.json.j2 b/ansible/roles/qdrouterd/templates/qdrouterd.json.j2 deleted file mode 100644 index 193ec196d6..0000000000 --- a/ansible/roles/qdrouterd/templates/qdrouterd.json.j2 +++ /dev/null @@ -1,29 +0,0 @@ -{ - "command": "/usr/sbin/qdrouterd", - "config_files": [ - { - "source": "{{ container_config_directory }}/qdrouterd.conf", - "dest": "/etc/qpid-dispatch/qdrouterd.conf", - "owner": "qdrouterd", - "perm": "0600" - }, - { - "source": "{{ container_config_directory }}/qdrouterd-sasl.conf", - "dest": "/etc/sasl2/qdrouterd.conf", - "owner": "qdrouterd", - "perm": "0600" - } - ], - "permissions": [ - { - "path": "/var/lib/qdrouterd", - "owner": "qdrouterd:qdrouterd", - "recurse": true - }, - { - "path": "/var/log/kolla/qdrouterd", - "owner": "qdrouterd:qdrouterd", - "recurse": true - } - ] -} diff --git a/ansible/roles/qdrouterd/vars/main.yml b/ansible/roles/qdrouterd/vars/main.yml deleted file mode 100644 index 1d04c1c001..0000000000 --- a/ansible/roles/qdrouterd/vars/main.yml +++ /dev/null @@ -1,2 +0,0 @@ ---- -project_name: "qdrouterd" diff --git a/ansible/site.yml b/ansible/site.yml index a2ede492d4..db3b94a336 100644 --- a/ansible/site.yml +++ b/ansible/site.yml @@ -62,7 +62,6 @@ - enable_ovn_{{ enable_ovn | bool }} - enable_placement_{{ enable_placement | bool }} - enable_prometheus_{{ enable_prometheus | bool }} - - enable_qdrouterd_{{ enable_qdrouterd | bool }} - enable_rabbitmq_{{ enable_rabbitmq | bool }} - enable_redis_{{ enable_redis | bool }} - enable_sahara_{{ enable_sahara | bool }} @@ -512,17 +511,6 @@ role_rabbitmq_user: '{{ outward_rabbitmq_user }}', when: enable_outward_rabbitmq | bool } -- name: Apply role qdrouterd - gather_facts: false - hosts: - - qdrouterd - - '&enable_qdrouterd_True' - serial: '{{ kolla_serial|default("0") }}' - roles: - - { role: qdrouterd, - tags: qdrouterd, - when: enable_qdrouterd | bool } - - name: Apply role etcd gather_facts: false hosts: diff --git a/etc/kolla/globals.yml b/etc/kolla/globals.yml index dd66c24530..c7cc5eda74 100644 --- a/etc/kolla/globals.yml +++ b/etc/kolla/globals.yml @@ -95,15 +95,6 @@ ################### # Messaging options ################### -# Below is an example of an separate backend that provides brokerless -# messaging for oslo.messaging RPC communications - -#om_rpc_transport: "amqp" -#om_rpc_user: "{{ qdrouterd_user }}" -#om_rpc_password: "{{ qdrouterd_password }}" -#om_rpc_port: "{{ qdrouterd_port }}" -#om_rpc_group: "qdrouterd" - # Whether to enable TLS for oslo.messaging communication with RabbitMQ. #om_enable_rabbitmq_tls: "{{ rabbitmq_enable_tls | bool }}" # CA certificate bundle in containers using oslo.messaging with RabbitMQ TLS. @@ -388,7 +379,6 @@ #enable_osprofiler: "no" #enable_placement: "{{ enable_nova | bool or enable_zun | bool }}" #enable_prometheus: "no" -#enable_qdrouterd: "{{ 'yes' if om_rpc_transport == 'amqp' else 'no' }}" #enable_redis: "no" #enable_sahara: "no" #enable_senlin: "no" diff --git a/etc/kolla/passwords.yml b/etc/kolla/passwords.yml index 86fd797279..5850342a96 100644 --- a/etc/kolla/passwords.yml +++ b/etc/kolla/passwords.yml @@ -210,11 +210,6 @@ gnocchi_project_id: gnocchi_resource_id: gnocchi_user_id: -#################### -# Qdrouterd options -#################### -qdrouterd_password: - #################### # RabbitMQ options #################### diff --git a/tests/templates/inventory.j2 b/tests/templates/inventory.j2 index 0fe61e6e9e..cb91545372 100644 --- a/tests/templates/inventory.j2 +++ b/tests/templates/inventory.j2 @@ -157,9 +157,6 @@ control [outward-rabbitmq:children] control -[qdrouterd:children] -control - [monasca-agent:children] compute control