Created
October 30, 2018 04:14
-
-
Save chadfurman/3112ef726db8fb12245e2d884c3543b3 to your computer and use it in GitHub Desktop.
test.sh
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
for WEBROOT in $(echo "webroot1 webroot2 webroot3") | |
do | |
echo $WEBROOT | |
HOSTNAME=`echo $WEBROOT | awk -F\/ '{print $NF}'` | |
echo $HOSTNAME | |
#touch /etc/letsencrypt/renewal/.$HOSTNAME | |
#ADDITIONALHOSTNAMELIST=`ls /etc/letsencrypt/renewal/.$HOSTNAME` | |
#echo -n "/usr/local/bin/certbot certonly -d $HOSTNAME"; cat $ADDITIONALHOSTNAMELIST | while read ADDITIONALHOSTNAME; do echo -n " -d ${ADDITIONALHOSTNAME}"; done; echo -n " --webroot -w $WEBROOT"; echo | |
# #$(echo -n "/usr/local/bin/certbot certonly -d $HOSTNAME"; cat $ADDITIONALHOSTNAMELIST | while read ADDITIONALHOSTNAME; do echo -n " -d ${ADDITIONALHOSTNAME}"; done; echo -n " --webroot -w $WEBROOT"; echo) | |
$(echo "ls $WEBROOT") | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment