Browse Source

Merge "Setup oslo.messaging extra packages for optional drivers"

Zuul 8 months ago
parent
commit
e2801ea743
2 changed files with 20 additions and 1 deletions
  1. 6
    1
      defaults/main.yml
  2. 14
    0
      tasks/designate_install_source.yml

+ 6
- 1
defaults/main.yml View File

@@ -95,7 +95,9 @@ designate_oslomsg_notify_userid: "{{ designate_oslomsg_rpc_userid }}"
95 95
 designate_oslomsg_notify_password: "{{ designate_oslomsg_rpc_password }}"
96 96
 designate_oslomsg_notify_vhost: "{{ designate_oslomsg_rpc_vhost }}"
97 97
 
98
-## RabbitMQ info
98
+## (Qdrouterd) info
99
+# TODO(ansmith): Change structure when more backends will be supported
100
+designate_oslomsg_amqp1_enabled: "{{ designate_oslomsg_rpc_transport == 'amqp' }}"
99 101
 
100 102
 ## Pool Configuration Defaults
101 103
 designate_pool_uuid: 794ccc2c-d751-44fe-b57f-8894c9f5c842
@@ -183,6 +185,9 @@ designate_pip_packages:
183 185
   - systemd-python
184 186
   - warlock
185 187
 
188
+designate_optional_oslomsg_amqp1_pip_packages:
189
+  - oslo.messaging[amqp1]
190
+
186 191
 designate_central_init_overrides: {}
187 192
 designate_worker_init_overrides: {}
188 193
 designate_producer_init_overrides: {}

+ 14
- 0
tasks/designate_install_source.yml View File

@@ -119,6 +119,20 @@
119 119
   tags:
120 120
     - skip_ansible_lint
121 121
 
122
+- name: Install optional pip packages
123
+  pip:
124
+    name: "{{ designate_optional_oslomsg_amqp1_pip_packages }}"
125
+    state: "{{ designate_pip_package_state }}"
126
+    virtualenv: "{{ designate_bin | dirname }}"
127
+    virtualenv_site_packages: "no"
128
+  when: designate_oslomsg_amqp1_enabled
129
+  register: install_optional_packages
130
+  until: install_optional_packages is success
131
+  retries: 5
132
+  delay: 2
133
+  notify:
134
+    - Restart designate services
135
+
122 136
 - name: Record the venv tag deployed
123 137
   ini_file:
124 138
     dest: "/etc/ansible/facts.d/openstack_ansible.fact"

Loading…
Cancel
Save