diff options
-rwxr-xr-x | nginx.sh | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -41,7 +41,9 @@ if ! $NGINX_DONE; then passenger=`ls -d passenger*` cd - >>$LOG 2>&1 servername=`hostname` - cmd="sed -i -e \"s/PASSENGER/$passenger/;s/SERVERNAME/$servername/;s/RUBY_DEST/$RUBY_DEST/;s/NGINX_DEST/$NGINX_DEST/\" ./nginx.conf" && run_cmd "$cmd" "Config" + ruby_dest=`echo $RUBY_DEST | sed 's/\//\\\//g'` + nginx_dest=`echo $NGINX_DEST | sed 's/\//\\\//g'` + cmd="sed -i -e \"s/PASSENGER/$passenger/;s/SERVERNAME/$servername/;s/RUBY_DEST/$ruby_dest/;s/NGINX_DEST/$nginx_dest/\" ./nginx.conf" && run_cmd "$cmd" "Config" cmd="cp ./nginx.conf \"$NGINX_DEST/conf\"" && run_cmd "$cmd" "Copy" fi |