X-Git-Url: https://plomlompom.com/repos/?a=blobdiff_plain;f=all_new_2018%2Fletsencrypt.sh;h=2e6a03b2194c06b1e71761dcd7975f063e1283a0;hb=77e391b5ded27dfcc9bfc7181c1d581adbaa0df6;hp=c89e37f660afabe10a5df008a06a3d5fdaee2824;hpb=51f9a28f9bd2e65cdaf51062a9586a0f747cf41b;p=config diff --git a/all_new_2018/letsencrypt.sh b/all_new_2018/letsencrypt.sh index c89e37f..2e6a03b 100755 --- a/all_new_2018/letsencrypt.sh +++ b/all_new_2018/letsencrypt.sh @@ -35,7 +35,7 @@ if [ "${action}" = "set" ]; then fi mail="$3" domain="$4" - ssh -t plom@${server} "su -c 'apt -y install certbot && certbot certonly --standalone --agree-tos -m ${mail} -d ${server}'" + ssh -t plom@${server} "su -c 'apt update && apt -y install certbot && certbot certonly --standalone --agree-tos -m ${mail} -d ${server}'" elif [ "${action}" = "get" ]; then # Get /etc/letsencrypt/ as tar file. ssh -t plom@${server} 'su -c "cd /etc/ && tar cf letsencrypt.tar letsencrypt && chown plom:plom letsencrypt.tar && mv letsencrypt.tar /home/plom/"'