This change should be applied after [bug/994744 b7fe11c] in python-keystoneclient.
Fixes bug 994744.
stable/essex note: keystoneclient trunk is used by stable/essex devstack
because there aren't stable branches for client libraries so we need
this change to pass devstack gate, currently failing with:
keystone user-role-add: error: ambiguous option: --user could match
--user-id, --user_id
Change-Id: I13e643f8552d86ed0bf92799271899f777bde9b2
... | ... |
@@ -56,19 +56,19 @@ ANOTHER_ROLE=$(get_id keystone role-create --name=anotherrole) |
56 | 56 |
|
57 | 57 |
|
58 | 58 |
# Add Roles to Users in Tenants |
59 |
-keystone user-role-add --user $ADMIN_USER --role $ADMIN_ROLE --tenant_id $ADMIN_TENANT |
|
60 |
-keystone user-role-add --user $ADMIN_USER --role $ADMIN_ROLE --tenant_id $DEMO_TENANT |
|
61 |
-keystone user-role-add --user $DEMO_USER --role $ANOTHER_ROLE --tenant_id $DEMO_TENANT |
|
59 |
+keystone user-role-add --user_id $ADMIN_USER --role_id $ADMIN_ROLE --tenant_id $ADMIN_TENANT |
|
60 |
+keystone user-role-add --user_id $ADMIN_USER --role_id $ADMIN_ROLE --tenant_id $DEMO_TENANT |
|
61 |
+keystone user-role-add --user_id $DEMO_USER --role_id $ANOTHER_ROLE --tenant_id $DEMO_TENANT |
|
62 | 62 |
|
63 | 63 |
# TODO(termie): these two might be dubious |
64 |
-keystone user-role-add --user $ADMIN_USER --role $KEYSTONEADMIN_ROLE --tenant_id $ADMIN_TENANT |
|
65 |
-keystone user-role-add --user $ADMIN_USER --role $KEYSTONESERVICE_ROLE --tenant_id $ADMIN_TENANT |
|
64 |
+keystone user-role-add --user_id $ADMIN_USER --role_id $KEYSTONEADMIN_ROLE --tenant_id $ADMIN_TENANT |
|
65 |
+keystone user-role-add --user_id $ADMIN_USER --role_id $KEYSTONESERVICE_ROLE --tenant_id $ADMIN_TENANT |
|
66 | 66 |
|
67 | 67 |
|
68 | 68 |
# The Member role is used by Horizon and Swift so we need to keep it: |
69 | 69 |
MEMBER_ROLE=$(get_id keystone role-create --name=Member) |
70 |
-keystone user-role-add --user $DEMO_USER --role $MEMBER_ROLE --tenant_id $DEMO_TENANT |
|
71 |
-keystone user-role-add --user $DEMO_USER --role $MEMBER_ROLE --tenant_id $INVIS_TENANT |
|
70 |
+keystone user-role-add --user_id $DEMO_USER --role_id $MEMBER_ROLE --tenant_id $DEMO_TENANT |
|
71 |
+keystone user-role-add --user_id $DEMO_USER --role_id $MEMBER_ROLE --tenant_id $INVIS_TENANT |
|
72 | 72 |
|
73 | 73 |
|
74 | 74 |
# Configure service users/roles |
... | ... |
@@ -77,16 +77,16 @@ NOVA_USER=$(get_id keystone user-create --name=nova \ |
77 | 77 |
--tenant_id $SERVICE_TENANT \ |
78 | 78 |
--email=nova@example.com) |
79 | 79 |
keystone user-role-add --tenant_id $SERVICE_TENANT \ |
80 |
- --user $NOVA_USER \ |
|
81 |
- --role $ADMIN_ROLE |
|
80 |
+ --user_id $NOVA_USER \ |
|
81 |
+ --role_id $ADMIN_ROLE |
|
82 | 82 |
|
83 | 83 |
GLANCE_USER=$(get_id keystone user-create --name=glance \ |
84 | 84 |
--pass="$SERVICE_PASSWORD" \ |
85 | 85 |
--tenant_id $SERVICE_TENANT \ |
86 | 86 |
--email=glance@example.com) |
87 | 87 |
keystone user-role-add --tenant_id $SERVICE_TENANT \ |
88 |
- --user $GLANCE_USER \ |
|
89 |
- --role $ADMIN_ROLE |
|
88 |
+ --user_id $GLANCE_USER \ |
|
89 |
+ --role_id $ADMIN_ROLE |
|
90 | 90 |
|
91 | 91 |
if [[ "$ENABLED_SERVICES" =~ "swift" ]]; then |
92 | 92 |
SWIFT_USER=$(get_id keystone user-create --name=swift \ |
... | ... |
@@ -94,8 +94,8 @@ if [[ "$ENABLED_SERVICES" =~ "swift" ]]; then |
94 | 94 |
--tenant_id $SERVICE_TENANT \ |
95 | 95 |
--email=swift@example.com) |
96 | 96 |
keystone user-role-add --tenant_id $SERVICE_TENANT \ |
97 |
- --user $SWIFT_USER \ |
|
98 |
- --role $ADMIN_ROLE |
|
97 |
+ --user_id $SWIFT_USER \ |
|
98 |
+ --role_id $ADMIN_ROLE |
|
99 | 99 |
# Nova needs ResellerAdmin role to download images when accessing |
100 | 100 |
# swift through the s3 api. The admin role in swift allows a user |
101 | 101 |
# to act as an admin for their tenant, but ResellerAdmin is needed |
... | ... |
@@ -103,8 +103,8 @@ if [[ "$ENABLED_SERVICES" =~ "swift" ]]; then |
103 | 103 |
# configurable in swift-proxy.conf |
104 | 104 |
RESELLER_ROLE=$(get_id keystone role-create --name=ResellerAdmin) |
105 | 105 |
keystone user-role-add --tenant_id $SERVICE_TENANT \ |
106 |
- --user $NOVA_USER \ |
|
107 |
- --role $RESELLER_ROLE |
|
106 |
+ --user_id $NOVA_USER \ |
|
107 |
+ --role_id $RESELLER_ROLE |
|
108 | 108 |
fi |
109 | 109 |
|
110 | 110 |
if [[ "$ENABLED_SERVICES" =~ "quantum" ]]; then |
... | ... |
@@ -113,6 +113,6 @@ if [[ "$ENABLED_SERVICES" =~ "quantum" ]]; then |
113 | 113 |
--tenant_id $SERVICE_TENANT \ |
114 | 114 |
--email=quantum@example.com) |
115 | 115 |
keystone user-role-add --tenant_id $SERVICE_TENANT \ |
116 |
- --user $QUANTUM_USER \ |
|
117 |
- --role $ADMIN_ROLE |
|
116 |
+ --user_id $QUANTUM_USER \ |
|
117 |
+ --role_id $ADMIN_ROLE |
|
118 | 118 |
fi |