Enable swift by default.
- Set by default SWIFT_REPLICAS to 1 since this is the most common use
case when using it in devstack.
- If we have swift_replicas to 1 launch the object container account and
proxy servers in foreground in screen.
- Allow any s- services if we have just 'swift' in service enabled
instead of having to specify all s- services to enable swift. This will be
removed in the future.
Change-Id: I496f79e14f99bd7e9f2c7deee12a4b6e935c3a5b
diff --git a/functions b/functions
index 11f7d50..3c7dabf 100644
--- a/functions
+++ b/functions
@@ -562,6 +562,9 @@
# **ceilometer** returns true if any service enabled start with **ceilometer**
# **glance** returns true if any service enabled start with **g-**
# **quantum** returns true if any service enabled start with **q-**
+# **swift** returns true if any service enabled start with **s-**
+# For backward compatibility if we have **swift** in ENABLED_SERVICES all the
+# **s-** services will be enabled. This will be deprecated in the future.
#
# Uses global ``ENABLED_SERVICES``
# is_service_enabled service [service ...]
@@ -574,6 +577,8 @@
[[ ${service} == "ceilometer" && ${ENABLED_SERVICES} =~ "ceilometer-" ]] && return 0
[[ ${service} == "glance" && ${ENABLED_SERVICES} =~ "g-" ]] && return 0
[[ ${service} == "quantum" && ${ENABLED_SERVICES} =~ "q-" ]] && return 0
+ [[ ${service} == "swift" && ${ENABLED_SERVICES} =~ "s-" ]] && return 0
+ [[ ${service} == s-* && ${ENABLED_SERVICES} =~ "swift" ]] && return 0
done
return 1
}