Compare commits
No commits in common. "master" and "th" have entirely different histories.
4 changed files with 8 additions and 23 deletions
|
|
@ -1,10 +1,10 @@
|
|||
FROM nginx:1.21.4-alpine
|
||||
|
||||
RUN mkdir -p /nginx /www_http
|
||||
RUN mkdir -p /nginx
|
||||
COPY nginx-http-redir.conf /nginx/default.conf
|
||||
|
||||
# For renewing the certificates
|
||||
COPY renew_cert.sh /etc/periodic/daily/renew_cert
|
||||
COPY renew_cert.sh /etc/periodic/daily/
|
||||
|
||||
RUN apk update && apk add certbot bind-tools
|
||||
|
||||
|
|
|
|||
11
README.md
11
README.md
|
|
@ -128,17 +128,6 @@ Added support for nginx webserver, based on official nginx image
|
|||
|
||||
- Add missing crond invocation
|
||||
|
||||
### 1.1.3
|
||||
|
||||
- Add missing http directory
|
||||
|
||||
### 1.1.4
|
||||
|
||||
- change renew_cert.sh file name for run-parts
|
||||
|
||||
### 1.1.5
|
||||
|
||||
- update renew_cert.sh for periodic renew
|
||||
|
||||
## Kubernetes
|
||||
|
||||
|
|
|
|||
|
|
@ -3,10 +3,10 @@ server {
|
|||
listen [::]:80;
|
||||
|
||||
server_name _;
|
||||
root /www_http;
|
||||
root /var/www/html/;
|
||||
|
||||
location /.well-known/acme-challenge/ {
|
||||
root /www_http;
|
||||
root /var/www/html;
|
||||
}
|
||||
|
||||
# Everything else -> ssl
|
||||
|
|
|
|||
|
|
@ -2,11 +2,10 @@
|
|||
|
||||
if [ "$NO_NGINX" ]; then
|
||||
/usr/bin/certbot renew --standalone
|
||||
elif [ -n "`grep -r standalone /etc/letsencrypt/renewal`" ]; then
|
||||
/usr/bin/certbot renew --standalone
|
||||
/usr/bin/certbot renew --force-renew --webroot --webroot-path /www_http
|
||||
else
|
||||
/usr/bin/certbot renew --webroot --webroot-path /www_http
|
||||
/usr/bin/certbot renew --webroot --webroot-path /var/www/html
|
||||
# Reload nginx
|
||||
pkill -1 nginx
|
||||
fi
|
||||
|
||||
# Correct permissions if not told otherwise
|
||||
|
|
@ -15,7 +14,4 @@ if [ -z "$LEAVE_PERMISSIONS_AS_IS" ]; then
|
|||
find /etc/letsencrypt -type f -exec chmod 0644 {} \;
|
||||
fi
|
||||
|
||||
# Reload certs
|
||||
pkill -1 nginx
|
||||
|
||||
echo "Last renew: $(date)" > /tmp/last_renew
|
||||
echo "Last renew: $(date)" > /tmp/last_renew
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue