add check for existing pem file
This commit is contained in:
parent
4aa1ec119a
commit
322bf2a82d
|
@ -57,7 +57,13 @@ done
|
|||
# check for domain (hostname)
|
||||
if [[ -z $domain ]]; then
|
||||
echo "domain (hostname) is required"
|
||||
exit
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# check for existing pem file
|
||||
if [[ -f /etc/ssl/letsencrypt/$domain.pem ]]; then
|
||||
echo "pem file for $domain already exists"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# set vars
|
||||
|
|
Loading…
Reference in New Issue
Block a user