14 lines
605 B
Bash
Executable File
14 lines
605 B
Bash
Executable File
#!/bin/sh
|
|
SSL_VOLUME_NAME=ssl_nginx_ssl
|
|
LETSENCRYPT_VOLUME_NAME=ssl_nginx_letsencrypt
|
|
|
|
if [ "$EMAIL" = '' ]; then
|
|
echo "Set EMAIL environment variable to run this!"
|
|
exit 1
|
|
fi
|
|
|
|
docker build --tag certbot_manual_test --build-arg EMAIL="$EMAIL" certbot
|
|
echo "ececute 'cat /run_once' to get commands list"
|
|
echo "for wildcard domains use manual mode with dns challange: 'certbot certonly -d '*.domain' --manual --preferred-challenges dns"
|
|
docker run -it --rm -v $SSL_VOLUME_NAME:/ssl -v $LETSENCRYPT_VOLUME_NAME:/etc/letsencrypt --entrypoint /bin/bash certbot_manual_test
|
|
docker rmi certbot_manual_test |