From 537ddff25987e79470613a605fdfc24629eaa862 Mon Sep 17 00:00:00 2001 From: Chmouel Boudjnah Date: Wed, 2 Nov 2011 19:09:30 +0100 Subject: [PATCH] Move all swift files to $FILES/swift/ --- .../account-server.conf} | 0 .../container-server.conf} | 0 .../object-server.conf} | 0 .../proxy-server.conf} | 0 files/{swift-rsyncd.conf => swift/rsyncd.conf} | 0 files/{ => swift}/swift-remakerings | 0 files/{ => swift}/swift-startmain | 0 files/{ => swift}/swift.conf | 0 stack.sh | 14 +++++++------- 9 files changed, 7 insertions(+), 7 deletions(-) rename files/{swift-account-server.conf => swift/account-server.conf} (100%) rename files/{swift-container-server.conf => swift/container-server.conf} (100%) rename files/{swift-object-server.conf => swift/object-server.conf} (100%) rename files/{swift-proxy-server.conf => swift/proxy-server.conf} (100%) rename files/{swift-rsyncd.conf => swift/rsyncd.conf} (100%) rename files/{ => swift}/swift-remakerings (100%) mode change 100644 => 100755 rename files/{ => swift}/swift-startmain (100%) rename files/{ => swift}/swift.conf (100%) diff --git a/files/swift-account-server.conf b/files/swift/account-server.conf similarity index 100% rename from files/swift-account-server.conf rename to files/swift/account-server.conf diff --git a/files/swift-container-server.conf b/files/swift/container-server.conf similarity index 100% rename from files/swift-container-server.conf rename to files/swift/container-server.conf diff --git a/files/swift-object-server.conf b/files/swift/object-server.conf similarity index 100% rename from files/swift-object-server.conf rename to files/swift/object-server.conf diff --git a/files/swift-proxy-server.conf b/files/swift/proxy-server.conf similarity index 100% rename from files/swift-proxy-server.conf rename to files/swift/proxy-server.conf diff --git a/files/swift-rsyncd.conf b/files/swift/rsyncd.conf similarity index 100% rename from files/swift-rsyncd.conf rename to files/swift/rsyncd.conf diff --git a/files/swift-remakerings b/files/swift/swift-remakerings old mode 100644 new mode 100755 similarity index 100% rename from files/swift-remakerings rename to files/swift/swift-remakerings diff --git a/files/swift-startmain b/files/swift/swift-startmain similarity index 100% rename from files/swift-startmain rename to files/swift/swift-startmain diff --git a/files/swift.conf b/files/swift/swift.conf similarity index 100% rename from files/swift.conf rename to files/swift/swift.conf diff --git a/stack.sh b/stack.sh index 3571df5..d8be465 100755 --- a/stack.sh +++ b/stack.sh @@ -617,7 +617,7 @@ if [[ "$ENABLED_SERVICES" =~ "n-net" ]]; then fi # Storage Service -if [[ "$ENABLED_SERVICES" =~ "swift" ]];then +if [[ "$ENABLED_SERVICES" =~ "swift" ]]; then # We first do a bit of setup by creating the directories and # changing the permissions so we can run it as our user. @@ -662,7 +662,7 @@ if [[ "$ENABLED_SERVICES" =~ "swift" ]];then # Swift use rsync to syncronize between all the different # partitions (which make more sense when you have a multi-node # setup) we configure it with our version of rsync. - sed -e "s/%GROUP%/${USER_GROUP}/;s/%USER%/$USER/;s,%SWIFT_LOCATION%,$SWIFT_LOCATION," $FILES/swift-rsyncd.conf | sudo tee /etc/rsyncd.conf + sed -e "s/%GROUP%/${USER_GROUP}/;s/%USER%/$USER/;s,%SWIFT_LOCATION%,$SWIFT_LOCATION," $FILES/swift/rsyncd.conf | sudo tee /etc/rsyncd.conf sudo sed -i '/^RSYNC_ENABLE=false/ { s/false/true/ }' /etc/default/rsync # By default Swift will be installed with the tempauth middleware @@ -682,9 +682,9 @@ if [[ "$ENABLED_SERVICES" =~ "swift" ]];then # We do the install of the proxy-server and swift configuration # replacing a few directives to match our configuration. sed "s/%USER%/$USER/;s/%SERVICE_TOKEN%/${SERVICE_TOKEN}/;s/%AUTH_SERVER%/${swift_auth_server}/" \ - $FILES/swift-proxy-server.conf|sudo tee /etc/swift/proxy-server.conf + $FILES/swift/proxy-server.conf|sudo tee /etc/swift/proxy-server.conf - sed -e "s/%SWIFT_HASH%/$SWIFT_HASH/" $FILES/swift.conf > /etc/swift/swift.conf + sed -e "s/%SWIFT_HASH%/$SWIFT_HASH/" $FILES/swift/swift.conf > /etc/swift/swift.conf # We need to generate a object/account/proxy configuration # emulating 4 nodes on different ports we have a little function @@ -698,7 +698,7 @@ if [[ "$ENABLED_SERVICES" =~ "swift" ]];then for node_number in {1..4};do node_path=${SWIFT_LOCATION}/${node_number} sed -e "s,%USER%,$USER,;s,%NODE_PATH%,${node_path},;s,%BIND_PORT%,${bind_port},;s,%LOG_FACILITY%,${log_facility}," \ - $FILES/swift-${server_type}-server.conf > /etc/swift/${server_type}-server/${node_number}.conf + $FILES/swift/${server_type}-server.conf > /etc/swift/${server_type}-server/${node_number}.conf bind_port=$(( ${bind_port} + 10 )) log_facility=$(( ${log_facility} + 1 )) done @@ -714,9 +714,9 @@ if [[ "$ENABLED_SERVICES" =~ "swift" ]];then # - swift-startmain # Restart your full cluster. # - sed -e "s/%SWIFT_PARTITION_POWER_SIZE%/$SWIFT_PARTITION_POWER_SIZE/" $FILES/swift-remakerings | \ + sed -e "s/%SWIFT_PARTITION_POWER_SIZE%/$SWIFT_PARTITION_POWER_SIZE/" $FILES/swift/swift-remakerings | \ sudo tee /usr/local/bin/swift-remakerings - sudo install -m755 $FILES/swift-startmain /usr/local/bin/ + sudo install -m755 $FILES/swift/swift-startmain /usr/local/bin/ sudo chmod +x /usr/local/bin/swift-* # We then can start rsync.