Skip to content

Commit a2bcb4c

Browse files
Zuulopenstack-gerrit
authored andcommitted
Merge "octavia: Ensure service auth project exists" into stable/victoria
2 parents 7bdabca + 1d6906b commit a2bcb4c

File tree

3 files changed

+14
-15
lines changed

3 files changed

+14
-15
lines changed

ansible/roles/octavia/defaults/main.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -146,6 +146,13 @@ octavia_ks_users:
146146
user: "{{ octavia_keystone_user }}"
147147
password: "{{ octavia_keystone_password }}"
148148
role: "admin"
149+
# NOTE(mgoddard): The default for the service auth project is service, but
150+
# may be customised. Ensure the project exists, and assign the octavia user
151+
# the admin role in it.
152+
- project: "{{ octavia_service_auth_project }}"
153+
user: "{{ octavia_keystone_user }}"
154+
password: "{{ octavia_keystone_password }}"
155+
role: "admin"
149156

150157
####################
151158
# Kolla

ansible/roles/octavia/tasks/register.yml

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -6,21 +6,6 @@
66
service_ks_register_services: "{{ octavia_ks_services }}"
77
service_ks_register_users: "{{ octavia_ks_users }}"
88

9-
- name: "Adding admin role to octavia user in {{ octavia_service_auth_project }} project"
10-
become: true
11-
kolla_toolbox:
12-
module_name: "os_user_role"
13-
module_args:
14-
user: "{{ octavia_keystone_user }}"
15-
role: admin
16-
project: "{{ octavia_service_auth_project }}"
17-
auth: "{{ openstack_octavia_auth }}"
18-
endpoint_type: "{{ openstack_interface }}"
19-
cacert: "{{ openstack_cacert }}"
20-
region_name: "{{ openstack_region_name }}"
21-
run_once: True
22-
when: octavia_service_auth_project != 'service'
23-
249
- name: Adding octavia related roles
2510
become: true
2611
kolla_toolbox:
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
---
2+
fixes:
3+
- |
4+
Fixes an issue with Octavia deployment when using a custom service auth
5+
project. If ``octavia_service_auth_project`` is set to a project that does
6+
not exist, Octavia deployment would fail. The project is now created.
7+
`LP#1922100 <https://bugs.launchpad.net/kolla-ansible/+bug/1922100>`__

0 commit comments

Comments
 (0)