Remove domain role from ceilometer, gnocchi service users
This patch removes the openstack_user resource with :grant_domain action. A user is always created within a specific domain; such a membership cannot be tacked on later. This resource gave the users the role intended for their project for the domain (i.e., for the Default domain instead of for the service project). We add the domain_name attribute that creates the users in the desired domain. Note that this change needs a sufficiently recent openstackclient cookbook -- otherwise the domain_name attribute is ignored (which does not matter as long as the users are to be created in the Default domain). Change-Id: Ie793b3d2e0419da90888edbf33ff28d819892dcf
This commit is contained in:
parent
9ad24ffd47
commit
88c718d574
|
@ -89,6 +89,7 @@ connection_params = {
|
|||
|
||||
# Register Service User
|
||||
openstack_user service_user do
|
||||
domain_name service_domain_name
|
||||
project_name service_tenant_name
|
||||
password service_pass
|
||||
connection_params connection_params
|
||||
|
@ -101,12 +102,4 @@ connection_params = {
|
|||
connection_params connection_params
|
||||
action :grant_role
|
||||
end
|
||||
|
||||
openstack_user service_user do
|
||||
domain_name service_domain_name
|
||||
role_name service_role
|
||||
user_name service_user
|
||||
connection_params connection_params
|
||||
action :grant_domain
|
||||
end
|
||||
end
|
||||
|
|
|
@ -75,22 +75,13 @@ describe 'openstack-telemetry::identity_registration' do
|
|||
expect(chef_run).to create_openstack_user(
|
||||
service_user
|
||||
).with(
|
||||
domain_name: domain_name,
|
||||
project_name: project_name,
|
||||
password: password,
|
||||
connection_params: connection_params
|
||||
)
|
||||
end
|
||||
|
||||
it do
|
||||
expect(chef_run).to grant_domain_openstack_user(
|
||||
service_user
|
||||
).with(
|
||||
domain_name: domain_name,
|
||||
role_name: role_name,
|
||||
connection_params: connection_params
|
||||
)
|
||||
end
|
||||
|
||||
it do
|
||||
expect(chef_run).to grant_role_openstack_user(
|
||||
service_user
|
||||
|
|
Loading…
Reference in New Issue