From 947aa6e1de50a726d0dcfe6081e058f2b6fdab46 Mon Sep 17 00:00:00 2001 From: Miriam Yumi Date: Fri, 21 Sep 2018 10:57:45 -0300 Subject: [PATCH] Fix tempest_roles for devstack plugin Currently the devstack plugin sets creator role for tempest user, but it may conflict with other roles already set to that configuration key. This patch adds the creator role to the list of roles instead of replacing its value. Change-Id: I8bdfc31bb2baeabe1d599ea6e9be3c473531f8b6 --- devstack/plugin.sh | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/devstack/plugin.sh b/devstack/plugin.sh index 122862b1e..0aaa94a7b 100644 --- a/devstack/plugin.sh +++ b/devstack/plugin.sh @@ -1,7 +1,13 @@ # Configure the needed tempest options function configure_barbican_tempest() { iniset $TEMPEST_CONFIG service_available barbican True - iniset $TEMPEST_CONFIG auth tempest_roles creator + roles="$(iniget $TEMPEST_CONFIG auth tempest_roles)" + if [[ -z $roles ]]; then + roles="creator" + else + roles="$roles,creator" + fi + iniset $TEMPEST_CONFIG auth tempest_roles $roles } # check for service enabled