mirror of https://github.com/zulip/zulip.git
Unset -e flag during humbug.pem login to preserve idempotency of install-server
(imported from commit d65b635a48ce33908b2888319a7c109d5d126b54)
This commit is contained in:
parent
b5eab2bde5
commit
bb2df13bfd
|
@ -32,6 +32,8 @@ fi
|
|||
# we'll get key errors after puppet apply.
|
||||
SSH_OPTS="-o HostKeyAlgorithms=ssh-rsa"
|
||||
|
||||
set +e
|
||||
|
||||
ssh $SSH_OPTS "$server" -t -i "$amazon_key_file" -ladmin <<EOF
|
||||
sudo sed -i 's/PermitRootLogin no/PermitRootLogin yes/g' /etc/ssh/sshd_config
|
||||
sudo mkdir ~root/.ssh && sudo cp .ssh/authorized_keys ~root/.ssh/authorized_keys
|
||||
|
@ -39,6 +41,8 @@ sudo service ssh restart
|
|||
|
||||
EOF
|
||||
|
||||
set -e
|
||||
|
||||
ssh $SSH_OPTS "$server" -t -i "$amazon_key_file" -lroot <<EOF
|
||||
echo "$hostname" > /etc/hostname
|
||||
sed -i 's/localhost$/localhost $hostname/' /etc/hosts
|
||||
|
|
Loading…
Reference in New Issue