lib/generators/lobot/templates/bootstrap_server.sh in lobot-0.9.7 vs lib/generators/lobot/templates/bootstrap_server.sh in lobot-0.10.0

- old
+ new

@@ -1,6 +1,7 @@ #!/bin/bash -e +RVM_0_12_3_SHA=d6b4de7cfec42f7ce33198f0bd82544af51e8aa5 env | grep -q "APP_USER=" || echo "Please set APP_USER environment variable" # perl -e 'print crypt("password", "salt"),"\n"' getent passwd $APP_USER >/dev/null 2>&1 || useradd $APP_USER -p DEADBEEFSCRYPTEDPASSWORD #sa3tHJ3/KuYvI would be password @@ -15,11 +16,11 @@ authorized_keys_string=`cat /root/.ssh/authorized_keys` grep -sq "$authorized_keys_string" /home/$APP_USER/.ssh/authorized_keys || cat /root/.ssh/authorized_keys >> /home/$APP_USER/.ssh/authorized_keys ## enable ssh password auth -perl -p -i -e 's/PasswordAuthentication no/PasswordAuthentication yes/' /etc/ssh/sshd_config +perl -p -i -e 's/PasswordAuthentication no/PasswordAuthentication yes/' /etc/ssh/sshd_config /etc/init.d/sshd reload # install epel rpm -q epel-release-5-4.noarch || rpm -Uvh http://mirrors.kernel.org/fedora-epel/5/x86_64/epel-release-5-4.noarch.rpm @@ -35,13 +36,13 @@ cat <<'BOOTSTRAP_AS_USER' > /home/$APP_USER/bootstrap_as_user.sh set -e export APP_USER=$1 - +export RVM_0_12_3_SHA=$2 mkdir -p /home/$APP_USER/rvm/src -curl -Lskf http://github.com/wayneeseguin/rvm/tarball/0f7135af8f0b6139716637d242a82442dd7fef09 | tar xvz -C/home/$APP_USER/rvm/src --strip 1 +curl -Lskf http://github.com/wayneeseguin/rvm/tarball/$RVM_0_12_3_SHA | tar xvz -C/home/$APP_USER/rvm/src --strip 1 cd "/home/$APP_USER/rvm/src" && ./install rvm_include_string='[[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm"' grep "$rvm_include_string" ~/.bashrc || echo "$rvm_include_string" >> ~/.bashrc @@ -51,7 +52,7 @@ rvm_gemset_create_on_use_flag=1 RVMRC_CONTENTS BOOTSTRAP_AS_USER chmod a+x /home/$APP_USER/bootstrap_as_user.sh -su - $APP_USER /home/$APP_USER/bootstrap_as_user.sh $APP_USER -rm /home/$APP_USER/bootstrap_as_user.sh \ No newline at end of file +su - $APP_USER /home/$APP_USER/bootstrap_as_user.sh $APP_USER $RVM_0_12_3_SHA +rm /home/$APP_USER/bootstrap_as_user.sh