Initial commit
This commit is contained in:
commit
bd92ae0776
4 changed files with 33 additions and 0 deletions
7
Dockerfile
Normal file
7
Dockerfile
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
FROM certbot/certbot:latest
|
||||||
|
|
||||||
|
COPY new-domain /usr/bin/new-domain
|
||||||
|
COPY renew /etc/periodic/monthly/renew
|
||||||
|
|
||||||
|
ENTRYPOINT /usr/sbin/crond -f
|
||||||
|
|
13
README.md
Normal file
13
README.md
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
# Certbot
|
||||||
|
|
||||||
|
This container wraps the certbot container with an additional script to help
|
||||||
|
with requesting new domains: [new-domain](./new-domain).
|
||||||
|
|
||||||
|
When using, make sure to mount the following folders:
|
||||||
|
|
||||||
|
Mount|Note
|
||||||
|
---|---
|
||||||
|
`/etc/letsencrypt`|Used to store requested certs
|
||||||
|
`/var/lib/letsencrypt`|Needed by LE
|
||||||
|
`/var/www/html/.well-known`|Needed for domain verification, needs to be the same directory as served by the web server
|
||||||
|
|
9
new-domain
Executable file
9
new-domain
Executable file
|
@ -0,0 +1,9 @@
|
||||||
|
#!/osr/bin/env sh
|
||||||
|
|
||||||
|
CMD="certbot certonly --webroot -w /var/www/html"
|
||||||
|
|
||||||
|
for domain in "$@"; do
|
||||||
|
CMD="$CMD -d $domain"
|
||||||
|
done
|
||||||
|
|
||||||
|
eval $CMD
|
4
renew
Normal file
4
renew
Normal file
|
@ -0,0 +1,4 @@
|
||||||
|
#!/usr/bin/env sh
|
||||||
|
|
||||||
|
/usr/local/bin/certbot renew
|
||||||
|
|
Loading…
Reference in a new issue