Browse Source

Use keystone_authtoken macros for auth

Change-Id: Icad4ff095133a318f7186b86a1a6fb91ddbbdb86
Depends-on: Icd3a2276097a52e77a31cb7eeeffb2d5bca8492b
Sergey Reshetnyak 2 years ago
parent
commit
c0b80d69ab
2 changed files with 5 additions and 15 deletions
  1. 1
    11
      service/files/heat.conf.j2
  2. 4
    4
      service/heat-api.yaml

+ 1
- 11
service/files/heat.conf.j2 View File

@@ -18,17 +18,7 @@ endpoint_type = internalURL
18 18
 [database]
19 19
 connection = mysql+pymysql://{{ heat.db.username }}:{{ heat.db.password }}@{{ address(service.database) }}/{{ heat.db.name }}
20 20
 
21
-[keystone_authtoken]
22
-auth_version = v3
23
-auth_uri = {{ address('keystone', keystone.public_port, with_scheme=True) }}/v3
24
-auth_url = {{ address('keystone', keystone.admin_port, with_scheme=True) }}/v3
25
-auth_type = password
26
-project_domain_id = default
27
-user_domain_id = default
28
-project_name = service
29
-username = {{ heat.user }}
30
-password = {{ heat.password }}
31
-memcached_servers = {{ address('memcached', memcached.port) }}
21
+{{ keystone_authtoken.keystone_authtoken(heat.user, heat.password) }}
32 22
 
33 23
 [trustee]
34 24
 user_domain_id = default

+ 4
- 4
service/heat-api.yaml View File

@@ -23,19 +23,19 @@ service:
23 23
           command: heat-manage db_sync
24 24
         - name: heat-user-create
25 25
           dependencies:
26
-            - keystone-create-project
26
+            - keystone-create-domain
27 27
           type: single
28 28
           command:
29
-            openstack user create --domain default --password {{ heat.password }} {{ heat.user }}
29
+            openstack user create --domain {{ service_account.domain }} --password {{ heat.password }} {{ heat.user }}
30 30
         - name: heat-admin-role-add
31 31
           dependencies:
32 32
             - heat-user-create
33 33
           type: single
34 34
           command:
35
-            openstack role add --project service --user {{ heat.user }} admin
35
+            openstack role add --domain {{ service_account.domain }} --user {{ heat.user }} admin
36 36
         - name: heat-service-create
37 37
           dependencies:
38
-            - keystone-create-project
38
+            - keystone
39 39
           type: single
40 40
           command:
41 41
             openstack service create --name heat --description "OpenStack orchestration service" orchestration

Loading…
Cancel
Save