Skip to content

Fixes certificate renewal #1286

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Aug 7, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions backend/internal/certificate.js
Original file line number Diff line number Diff line change
Expand Up @@ -758,6 +758,7 @@ const internalCertificate = {
},

/**
* Request a certificate using the http challenge
* @param {Object} certificate the certificate row
* @returns {Promise}
*/
Expand All @@ -768,6 +769,7 @@ const internalCertificate = {
'--config "' + letsencryptConfig + '" ' +
'--cert-name "npm-' + certificate.id + '" ' +
'--agree-tos ' +
'--authenticator webroot ' +
'--email "' + certificate.meta.letsencrypt_email + '" ' +
'--preferred-challenges "dns,http" ' +
'--domains "' + certificate.domain_names.join(',') + '" ' +
Expand Down
2 changes: 2 additions & 0 deletions backend/templates/default.conf
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ server {
error_log /data/logs/default-host_error.log warn;
{% include "_exploits.conf" %}

include conf.d/include/letsencrypt-acme-challenge.conf;

{%- if value == "404" %}
location / {
return 404;
Expand Down
1 change: 0 additions & 1 deletion docker/rootfs/etc/letsencrypt.ini
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
text = True
non-interactive = True
authenticator = webroot
webroot-path = /data/letsencrypt-acme-challenge
3 changes: 2 additions & 1 deletion docker/rootfs/etc/nginx/conf.d/default.conf
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,10 @@ server {

server_name localhost-nginx-proxy-manager;
access_log /data/logs/fallback_access.log standard;
error_log /dev/null crit;
error_log /data/logs/fallback_error.log warn;
include conf.d/include/assets.conf;
include conf.d/include/block-exploits.conf;
include conf.d/include/letsencrypt-acme-challenge.conf;

location / {
index index.html;
Expand Down