Browse code

Merge "Increase Swift disk size up to 2GB if Glance is enabled"

Jenkins authored on 2015/03/26 21:51:03
Showing 1 changed files
... ...
@@ -64,11 +64,19 @@ if is_service_enabled s-proxy && is_service_enabled swift3; then
64 64
     S3_SERVICE_PORT=${S3_SERVICE_PORT:-8080}
65 65
 fi
66 66
 
67
-# DevStack will create a loop-back disk formatted as XFS to store the
68
-# swift data. Set ``SWIFT_LOOPBACK_DISK_SIZE`` to the disk size in
69
-# kilobytes.
70
-# Default is 1 gigabyte.
71
-SWIFT_LOOPBACK_DISK_SIZE_DEFAULT=1G
67
+if is_service_enabled g-api; then
68
+    # Minimum Cinder volume size is 1G so if Swift backend for Glance is
69
+    # only 1G we can not upload volume to image.
70
+    # Increase Swift disk size up to 2G
71
+    SWIFT_LOOPBACK_DISK_SIZE_DEFAULT=2G
72
+else
73
+    # DevStack will create a loop-back disk formatted as XFS to store the
74
+    # swift data. Set ``SWIFT_LOOPBACK_DISK_SIZE`` to the disk size in
75
+    # kilobytes.
76
+    # Default is 1 gigabyte.
77
+    SWIFT_LOOPBACK_DISK_SIZE_DEFAULT=1G
78
+fi
79
+
72 80
 # if tempest enabled the default size is 6 Gigabyte.
73 81
 if is_service_enabled tempest; then
74 82
     SWIFT_LOOPBACK_DISK_SIZE_DEFAULT=${SWIFT_LOOPBACK_DISK_SIZE:-6G}