From 4cf1d03f9f6a4bce321beded50225f7d80d3c9e9 Mon Sep 17 00:00:00 2001 From: Ryan Bak Date: Thu, 5 May 2016 13:11:57 -0600 Subject: [PATCH] Fix for custom agent roles Previously user_roles_agent and user_roles_user were ignored Change-Id: I5c69bbb4cc57b0dbbdbd3d1c2c4a65c2e0dbae58 --- manifests/keystone/auth.pp | 19 ++++++++----------- 1 file changed, 8 insertions(+), 11 deletions(-) diff --git a/manifests/keystone/auth.pp b/manifests/keystone/auth.pp index 1d3ea9e..6f4d293 100644 --- a/manifests/keystone/auth.pp +++ b/manifests/keystone/auth.pp @@ -225,8 +225,7 @@ class monasca::keystone::auth ( if $user_roles_agent { $real_user_roles_agent = $user_roles_agent } else { - $real_user_roles_agent = [Keystone_role[$role_agent], - Keystone_role[$role_delegate]] + $real_user_roles_agent = [$role_agent, $role_delegate] } if $user_roles_admin { $real_user_roles_admin = $user_roles_admin @@ -236,20 +235,18 @@ class monasca::keystone::auth ( if $user_roles_user { $real_user_roles_user = $user_roles_user } else { - $real_user_roles_user = [Keystone_role[$role_user]] + $real_user_roles_user = [$role_user] } keystone_user_role { "${agent_name}@${tenant}": - ensure => present, - roles => [$role_agent, $role_delegate], - require => $real_user_roles_agent, - before => Service['monasca-agent'], + ensure => present, + roles => $real_user_roles_agent, + before => Service['monasca-agent'], } keystone_user_role { "${user_name}@${tenant}": - ensure => present, - roles => [$role_user], - require => $real_user_roles_user, - before => Service['monasca-agent'], + ensure => present, + roles => $real_user_roles_user, + before => Service['monasca-agent'], } }