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/rabbitmq | |
| 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/rabbitmq')
| -rw-r--r-- | docker/common/rabbitmq/config-external.sh | 21 |
1 files changed, 13 insertions, 8 deletions
diff --git a/docker/common/rabbitmq/config-external.sh b/docker/common/rabbitmq/config-external.sh index 40abd6156..33810d621 100644 --- a/docker/common/rabbitmq/config-external.sh +++ b/docker/common/rabbitmq/config-external.sh @@ -1,14 +1,19 @@ #!/bin/bash +SOURCE_CONFIG="/opt/kolla/rabbitmq/rabbitmq.config" +TARGET_CONFIG="/etc/rabbitmq/rabbitmq.config" +SOURCE_ENV="/opt/kolla/rabbitmq/rabbitmq-env.conf" +TARGET_ENV="/etc/rabbitmq/rabbitmq-env.conf" +OWNER="rabbitmq" # Cluster configuration -if [[ -f /opt/kolla/rabbitmq/rabbitmq.config ]]; then - cp -af /opt/kolla/rabbitmq/rabbitmq.config /etc/rabbitmq/rabbitmq.config - chown rabbitmq: /etc/rabbitmq/rabbitmq.config - chmod 0600 /etc/rabbitmq/rabbitmq.config +if [[ -f "$SOURCE_CONFIG" ]]; then + cp -af $SOURCE_CONFIG $TARGET_CONFIG + chown ${OWNER}: $TARGET_CONFIG + chmod 0600 $TARGET_CONFIG fi -if [[ -f /opt/kolla/rabbitmq/rabbitmq-env.conf ]]; then - cp -af /opt/kolla/rabbitmq/rabbitmq-env.conf /etc/rabbitmq/rabbitmq-env.conf - chown rabbitmq: /etc/rabbitmq/rabbitmq-env.conf - chmod 0600 /etc/rabbitmq/rabbitmq-env.conf +if [[ -f "$SOURCE_ENV" ]]; then + cp -af $SOURCE_ENV $TARGET_ENV + chown ${OWNER}: $TARGET_ENV + chmod 0600 $TARGET_ENV fi |
