Browse code

Merge "Fix account rc files creation for Swift users"

Jenkins authored on 2014/10/14 00:20:46
Showing 2 changed files
... ...
@@ -557,9 +557,11 @@ function create_swift_disk {
557 557
 
558 558
 function create_swift_accounts {
559 559
     # Defines specific passwords used by tools/create_userrc.sh
560
-    local swiftusertest1_password=testing
561
-    local swiftusertest2_password=testing2
562
-    local swiftusertest3_password=testing3
560
+    # As these variables are used by create_userrc.sh, they must be exported
561
+    # The _password suffix is expected by create_userrc.sh
562
+    export swiftusertest1_password=testing
563
+    export swiftusertest2_password=testing2
564
+    export swiftusertest3_password=testing3
563 565
 
564 566
     KEYSTONE_CATALOG_BACKEND=${KEYSTONE_CATALOG_BACKEND:-sql}
565 567
 
... ...
@@ -254,7 +254,8 @@ if [ $MODE != "create" ]; then
254 254
 
255 255
             # Checks for a specific password defined for an user.
256 256
             # Example for an username johndoe: JOHNDOE_PASSWORD=1234
257
-            eval SPECIFIC_UPASSWORD="\$${USER_NAME^^}_PASSWORD"
257
+            # This mechanism is used by lib/swift
258
+            eval SPECIFIC_UPASSWORD="\$${user_name}_password"
258 259
             if [ -n "$SPECIFIC_UPASSWORD" ]; then
259 260
                 USER_PASS=$SPECIFIC_UPASSWORD
260 261
             fi