Update init.sh
This commit is contained in:
parent
dc6a1b7d9a
commit
6a4a1856b6
10
init.sh
10
init.sh
@ -1,7 +1,14 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
# run as root
|
# fetch and run this in cloud-init, viz:
|
||||||
|
|
||||||
|
##cloud-config
|
||||||
|
#runcmd:
|
||||||
|
# - curl -fsSL https://raw.githubusercontent.com/sneak/hacks/master/init.sh | bash
|
||||||
|
|
||||||
|
#exec 1 2>&1 | tee -a ${LOG_FILE}
|
||||||
|
|
||||||
|
export DEBIAN_FRONTEND=noninteractive
|
||||||
apt-get update
|
apt-get update
|
||||||
apt-get -y upgrade
|
apt-get -y upgrade
|
||||||
apt-get -y install vim byobu screen build-essential git
|
apt-get -y install vim byobu screen build-essential git
|
||||||
@ -21,7 +28,6 @@ fi
|
|||||||
if [[ ! -e /home/sneak/.ssh/sneak.keys ]]; then
|
if [[ ! -e /home/sneak/.ssh/sneak.keys ]]; then
|
||||||
cd /home/sneak/.ssh && \
|
cd /home/sneak/.ssh && \
|
||||||
wget https://github.com/sneak.keys && \
|
wget https://github.com/sneak.keys && \
|
||||||
mv authorized_keys authorized-keys-orig.keys && \
|
|
||||||
cat *.keys > authorized_keys
|
cat *.keys > authorized_keys
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user