evoacme: always strip .conf suffix

This commit is contained in:
Victor LABORIE 2017-05-10 10:50:28 +02:00
parent 42834aa438
commit 3738a189c7
2 changed files with 2 additions and 2 deletions

View file

@ -5,7 +5,7 @@
[ -z "${CSR_DIR}" ] && CSR_DIR='/etc/ssl/requests'
[ -z "${SELF_SIGNED_DIR}" ] && SELF_SIGNED_DIR='/etc/ssl/self-signed'
vhost=$1
vhost=$(basename $1 .conf)
SSL_EMAIL=$(grep emailAddress /etc/letsencrypt/openssl.cnf|cut -d'=' -f2|xargs)
if [ -n "$SSL_EMAIL" ]; then

View file

@ -7,7 +7,7 @@
shopt -s extglob
vhost=$1
vhost=$(basename $1 .conf)
vhostfiles=$(ls -1 /etc/{nginx,apache2}/sites-enabled/${vhost}?(.conf) 2>/dev/null)
if [ $(echo "${vhostfiles}"|wc -l) -lt 1 ]; then