30 Commits

Author SHA1 Message Date
6134b05328 Merge pull request '1.1.0' (#5) from develop into master
All checks were successful
continuous-integration/drone/push Build is passing
continuous-integration/drone/tag Build is passing
Reviewed-on: #5
2023-07-16 17:08:41 +00:00
ada326f2d8 tweak log formatting
All checks were successful
continuous-integration/drone/push Build is passing
2023-07-16 16:45:36 +00:00
5d14d166eb add multi-certificate support
All checks were successful
continuous-integration/drone/push Build is passing
2023-07-16 15:37:12 +00:00
3a6466612b enable tracking of env vars between runs
All checks were successful
continuous-integration/drone/push Build is passing
2023-07-15 16:04:45 +00:00
36b71a0ebb add standalone and webroot methods
All checks were successful
continuous-integration/drone/push Build is passing
2023-07-09 21:53:06 +00:00
e0da513893 Merge pull request '1.0.0' (#4) from develop into master
All checks were successful
continuous-integration/drone/push Build is passing
continuous-integration/drone/tag Build is passing
Reviewed-on: #4
2023-06-21 18:20:15 +00:00
df56fcf997 make CLOUDFLARE_TOKEN override instead of append
All checks were successful
continuous-integration/drone/push Build is passing
2023-06-21 17:48:29 +00:00
3c3cc47d32 add CLOUDFLARE_TOKEN to env vars
All checks were successful
continuous-integration/drone/push Build is passing
2023-06-21 17:32:17 +00:00
053cef4c31 add build dependencies for arm
All checks were successful
continuous-integration/drone/push Build is passing
2023-06-20 22:14:44 +00:00
b6d93c1164 update readme
Some checks failed
continuous-integration/drone/push Build is failing
2023-06-20 21:27:42 +00:00
a41c409f9d update build logic 2023-06-20 21:27:36 +00:00
e859aa7218 add goreleaser 2023-06-20 21:27:27 +00:00
a4b59c360e change to s6 2023-06-20 21:27:01 +00:00
e7bd87d5bd change to alpine 2023-06-20 21:26:11 +00:00
6ef0abfd6b Update 'README.md'
All checks were successful
continuous-integration/drone/push Build is passing
2023-01-02 16:40:31 +00:00
868eb4eb59 Update '.drone.yml'
All checks were successful
continuous-integration/drone/push Build is passing
2022-12-25 20:38:20 +00:00
578284bb10 Update '.drone.yml'
All checks were successful
continuous-integration/drone/push Build is passing
2022-12-25 19:18:06 +00:00
e10bdd741d Update 'README.md' 2022-12-25 19:09:13 +00:00
0aa35c3ef6 Update 'README.md' 2022-12-25 19:07:54 +00:00
90f5095eef Add '.drone.yml' 2022-12-25 18:50:54 +00:00
3daee369ca Update 'README.md' 2022-12-25 18:48:33 +00:00
6a27c9232c Update 'README.md' 2022-06-21 16:56:35 +00:00
e130fc041e Prevented dhparams regenerating if they already exist 2022-06-21 11:58:46 +00:00
591e35c91a Formatting 2022-06-20 22:42:29 +00:00
375cf5da74 Add GENERATE_DHPARAM 2022-06-20 22:41:27 +00:00
09eb18adda Added PROPOGATION_TIME variable 2022-06-20 22:08:30 +00:00
d09988c241 Update 'README.md' 2022-06-19 17:11:20 +00:00
6d696dd4b2 Fix typo 2022-06-18 23:12:11 +00:00
c23657ce01 Formatting fix 2022-06-18 23:10:07 +00:00
634f0cac4a first commit 2022-06-18 23:08:39 +00:00
10 changed files with 4 additions and 33 deletions

View File

@ -17,7 +17,6 @@ ENV PGID=1000
ENV TZ=UTC
ENV GENERATE_DHPARAM=true
ENV INTERVAL="0 */6 * * *"
ENV ONE_SHOT=false
# Single domain
ENV DOMAINS=
@ -56,10 +55,7 @@ ENV S6_BEHAVIOUR_IF_STAGE2_FAILS=2 S6_CMD_WAIT_FOR_SERVICES_MAXTIME=0 S6_VERBOSI
RUN python3 -m venv /app/certbot/ && /app/certbot/bin/pip install --upgrade pip
#Get required packages for building, build, then cleanup
#Added additional pip steps to fix cython 3.0.0 issue - https://github.com/yaml/pyyaml/issues/601
RUN apk add --no-cache --virtual .deps gcc python3-dev libc-dev libffi-dev && \
/app/certbot/bin/pip install wheel && \
/app/certbot/bin/pip install "Cython<3.0" pyyaml --no-build-isolation && \
/app/certbot/bin/pip install certbot certbot-dns-cloudflare && \
ln -s /app/certbot/bin/certbot /usr/bin/certbot &&\
apk del .deps
@ -69,7 +65,6 @@ COPY root /
RUN chmod +x /container-init.sh && \
chmod +x /certbot-prepare.sh && \
chmod +x /certbot-renew.sh && \
chmod +x /check-one-shot.sh && \
chown -R ${PUID}:${PGID} /app /config
ENTRYPOINT [ "/init" ]

View File

@ -52,7 +52,6 @@ Core options to the container
|PUID |int |1000 |Sets the UID of the user certbot runs under |
|PGID |int |1000 |Sets the GID of the user certbot runs under |
|TZ |[List of valid TZs](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones#List) |UTC |Sets the timezone of the container |
| ONE_SHOT | false | Whether container exits after first run of certbot, or starts cron-based auto-renewal |
| GENERATE_DHPARAM | true (case-sensitive) | Generate Diffie-Hellman keys in /config/letsencrypt/keys |
| INTERVAL | 0 */6 * * * | How often certbot attempts to renew the certificate. Cron syntax |
| CERT_COUNT | 1 | How many certificates certbot will try to issue (more than 1 not yet implemented) |

View File

@ -756,24 +756,13 @@ fi
if [ $GENERATE_DHPARAM = true ] && [ ! -s /config/letsencrypt/keys/ssl-dhparams.pem ]
then
echo ""
echo "Generating Diffie-Hellman keys, saved to /config/letsencrypt/keys. This can take a long time!"
openssl dhparam -out /config/letsencrypt/keys/ssl-dhparams.pem 4096
fi
if [ $ONE_SHOT == "true" ]; then
echo ""
echo "ONE_SHOT is true - exiting container"
elif [ $ONE_SHOT == "false" ]; then
echo "$INTERVAL /certbot-renew.sh >> /config/logs/renew.log" > /config/.crontab.txt
echo ""
echo "Starting automatic renewal job. Schedule is $INTERVAL"
crontab /config/.crontab.txt
fi

View File

@ -1,9 +0,0 @@
#!/command/with-contenv bash
# shellcheck shell=bash
if [ $ONE_SHOT == "true" ]; then
# Cleanly kill container by sending kill signal to supervisor process
kill 1
fi

View File

@ -28,7 +28,6 @@ echo \
"PUID=${PUID}
PGID=${PGID}
TZ=${TZ}
ONE_SHOT=${ONE_SHOT}
INTERVAL=${INTERVAL}
GENERATE_DHPARAM=${GENERATE_DHPARAM}
CERT_COUNT=${CERT_COUNT}"

View File

@ -1 +0,0 @@
oneshot

View File

@ -1 +0,0 @@
exec /check-one-shot.sh