From 88d54996db69113e2ac5d9e5347072faa959cec7 Mon Sep 17 00:00:00 2001 From: Chmouel Boudjnah Date: Wed, 2 Nov 2011 01:10:38 +0100 Subject: [PATCH] Don't use 'stack' in static but use $USER. --- files/swift-account-server.conf | 2 +- files/swift-container-server.conf | 2 +- files/swift-object-server.conf | 2 +- files/swift-proxy-server.conf | 2 +- stack.sh | 4 ++-- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/files/swift-account-server.conf b/files/swift-account-server.conf index b5451c6..920d45c 100644 --- a/files/swift-account-server.conf +++ b/files/swift-account-server.conf @@ -2,7 +2,7 @@ devices = %NODE_PATH%/node mount_check = false bind_port = %BIND_PORT% -user = stack +user = %USER% log_facility = LOG_LOCAL%LOG_FACILITY% [pipeline:main] diff --git a/files/swift-container-server.conf b/files/swift-container-server.conf index c630076..8d59bf2 100644 --- a/files/swift-container-server.conf +++ b/files/swift-container-server.conf @@ -2,7 +2,7 @@ devices = %NODE_PATH%/node mount_check = false bind_port = %BIND_PORT% -user = stack +user = %USER% log_facility = LOG_LOCAL%LOG_FACILITY% [pipeline:main] diff --git a/files/swift-object-server.conf b/files/swift-object-server.conf index 4a00713..1b72e70 100644 --- a/files/swift-object-server.conf +++ b/files/swift-object-server.conf @@ -2,7 +2,7 @@ devices = %NODE_PATH%/node mount_check = false bind_port = %BIND_PORT% -user = stack +user = %USER% log_facility = LOG_LOCAL%LOG_FACILITY% [pipeline:main] diff --git a/files/swift-proxy-server.conf b/files/swift-proxy-server.conf index 9a3b54b..6b7dd52 100644 --- a/files/swift-proxy-server.conf +++ b/files/swift-proxy-server.conf @@ -1,6 +1,6 @@ [DEFAULT] bind_port = 8080 -user = stack +user = %USER% log_facility = LOG_LOCAL1 [pipeline:main] diff --git a/stack.sh b/stack.sh index 9ba0564..62be7f5 100755 --- a/stack.sh +++ b/stack.sh @@ -655,7 +655,7 @@ if [[ "$ENABLED_SERVICES" =~ "swift" ]];then swift_auth_server=tempauth fi - sed "s/%SERVICE_TOKEN%/${SERVICE_TOKEN}/;s/%AUTH_SERVER%/${swift_auth_server}/" \ + 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 # Generate swift.conf, we need to have the swift-hash being random @@ -673,7 +673,7 @@ if [[ "$ENABLED_SERVICES" =~ "swift" ]];then for node_number in {1..4};do node_path=${SWIFT_LOCATION}/${node_number} - sed -e "s,%NODE_PATH%,${node_path},;s,%BIND_PORT%,${bind_port},;s,%LOG_FACILITY%,${log_facility}," \ + 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 bind_port=$(( ${bind_port} + 10 )) log_facility=$(( ${log_facility} + 1 ))