]>
jfr.im git - z_archive/vpsm.git/blob - install.sh
1 TGZ_URL
="" # default link and stuff
6 if ! grep "vpsm" /etc
/passwd
>/dev
/null
2>&1; then
7 adduser
-M -d /opt
/vpsm
/ -c "VPSM user" -s /opt
/vpsm
/shell vpsm
16 if [ "$TGZ_URL" ]; then
17 wget
-O vpsm.tgz
"$TGZ_URL"
19 read -e -p "Save the node distribution as /opt/vpsm/vpsm.tgz and press enter..." somevar
25 if [ -z "$PUBKEY_URL" ]; then
26 read -e -p "Type URL to VPSM's public key (or just press enter to not fetch): " PUBKEY_URL
28 if [ "$PUBKEY_URL" ]; then
29 wget
-O - "$PUBKEY_URL" >>/opt
/vpsm
/.ssh
/authorized_keys
32 # Last step: chown/chmod
33 chown
-R vpsm
: /opt
/vpsm
35 chmod 755 /opt
/vpsm
/shell
36 chmod 700 /opt
/vpsm
/.ssh
/
37 chmod 600 /opt
/vpsm
/.ssh
/authorized_keys