first commit
This commit is contained in:
17
cerbotForHaproxy.sh
Executable file
17
cerbotForHaproxy.sh
Executable file
@@ -0,0 +1,17 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Vérifie qu'un domaine a été passé en argument
|
||||
if [ -z "$1" ]; then
|
||||
echo "Usage: $0 domaine.com"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
DOMAIN="$1"
|
||||
|
||||
# Exécution de certbot
|
||||
certbot certonly --standalone -d "$DOMAIN"
|
||||
|
||||
|
||||
cat /etc/letsencrypt/live/"$DOMAIN"/privkey.pem \
|
||||
/etc/letsencrypt/live/"$DOMAIN"/fullchain.pem \
|
||||
> /home/certificate/"$DOMAIN".pem
|
||||
Reference in New Issue
Block a user