diff options
| author | xiabing.yao <yao.xiabing@99cloud.net> | 2015-08-06 17:32:56 +0800 |
|---|---|---|
| committer | xiabing.yao <yao.xiabing@99cloud.net> | 2015-08-06 22:27:28 +0800 |
| commit | b11321cedcfca8c394eefffae9589eba9b470fa2 (patch) | |
| tree | 14a01751c09f58588daa1cf2206126b8a24b53e8 /docker/common/swift/swift-container-server | |
| parent | 20deecda98f457fdff7ae5bb41fcdd3f0ff5362f (diff) | |
| download | kolla-b11321cedcfca8c394eefffae9589eba9b470fa2.tar.gz kolla-b11321cedcfca8c394eefffae9589eba9b470fa2.zip | |
update config-external.sh in galera,keystone,rabbitmq,swift
Use variables like SOURCE,TARGET in config-external.sh, so
it will easy to modify in future.
Closes-Bug: #1485710
Change-Id: I3880a2cbca8a80d36e84a797fcfb943e43b88bd5
Diffstat (limited to 'docker/common/swift/swift-container-server')
| -rw-r--r-- | docker/common/swift/swift-container-server/config-external.sh | 21 |
1 files changed, 13 insertions, 8 deletions
diff --git a/docker/common/swift/swift-container-server/config-external.sh b/docker/common/swift/swift-container-server/config-external.sh index 6f4186e0f..93f696349 100644 --- a/docker/common/swift/swift-container-server/config-external.sh +++ b/docker/common/swift/swift-container-server/config-external.sh @@ -1,13 +1,18 @@ #!/bin/bash +SOURCE="/opt/kolla/swift/swift.conf" +TARGET="/etc/swift/swift.conf" +SOURCE_CONTAINER_SERVER="/opt/kolla/swift/container-server.conf" +TARGET_CONTAINER_SERVER="/etc/swift/container-server.conf" +OWNER="swift" -if [[ -f /opt/kolla/swift/swift.conf ]]; then - cp /opt/kolla/swift/swift.conf /etc/swift/ - chown swift: /etc/swift/swift.conf - chmod 0640 /etc/swift/swift.conf +if [[ -f "$SOURCE" ]]; then + cp $SOURCE $TARGET + chown ${OWNER}: $TARGET + chmod 0640 $TARGET fi -if [[ -f /opt/kolla/swift/container-server.conf ]]; then - cp /opt/kolla/swift/container-server.conf /etc/swift/ - chown swift: /etc/swift/container-server.conf - chmod 0640 /etc/swift/container-server.conf +if [[ -f "$SOURCE_CONTAINER_SERVER" ]]; then + cp $SOURCE_CONTAINER_SERVER $TARGET_CONTAINER_SERVER + chown ${OWNER}: $TARGET_CONTAINER_SERVER + chmod 0640 $TARGET_CONTAINER_SERVER fi |
