mirror of
https://github.com/NginxProxyManager/nginx-proxy-manager.git
synced 2025-06-18 10:06:26 +00:00
Merge branch 'develop' into develop
This commit is contained in:
@ -1,5 +1,6 @@
|
||||
/data/logs/*_access.log /data/logs/*/access.log {
|
||||
create 0644 root root
|
||||
su npm npm
|
||||
create 0644
|
||||
weekly
|
||||
rotate 4
|
||||
missingok
|
||||
@ -12,7 +13,8 @@
|
||||
}
|
||||
|
||||
/data/logs/*_error.log /data/logs/*/error.log {
|
||||
create 0644 root root
|
||||
su npm npm
|
||||
create 0644
|
||||
weekly
|
||||
rotate 10
|
||||
missingok
|
||||
|
@ -1,9 +1,12 @@
|
||||
# Since force-ssl.conf has now moved to the server section it overrides
|
||||
# the LetsEncrypt config which is inside a location section
|
||||
# Set FORCE variable in first two if tests pass and action in the third
|
||||
set $FORCE "";
|
||||
set $test "";
|
||||
if ($scheme = "http") {
|
||||
set $FORCE 'H';
|
||||
set $test "H";
|
||||
}
|
||||
if ($request_uri ~ "^\/\.well-known\/acme-challenge\/(.*)" {
|
||||
set $test "${test}T";
|
||||
}
|
||||
if ($test = H) {
|
||||
return 301 https://$host$request_uri;
|
||||
}
|
||||
if ($request_uri !~ "^\/\.well-known\/acme-challenge\/(.*)") {
|
||||
set $FORCE "${FORCE}D";
|
||||
|
@ -3,7 +3,7 @@
|
||||
|
||||
set -e
|
||||
|
||||
. /bin/common.sh
|
||||
. /usr/bin/common.sh
|
||||
|
||||
cd /app || exit 1
|
||||
|
||||
|
@ -6,7 +6,7 @@ set -e
|
||||
# This service is DEVELOPMENT only.
|
||||
|
||||
if [ "$DEVELOPMENT" = 'true' ]; then
|
||||
. /bin/common.sh
|
||||
. /usr/bin/common.sh
|
||||
cd /app/frontend || exit 1
|
||||
HOME=$NPMHOME
|
||||
export HOME
|
||||
|
@ -3,7 +3,7 @@
|
||||
|
||||
set -e
|
||||
|
||||
. /bin/common.sh
|
||||
. /usr/bin/common.sh
|
||||
|
||||
log_info 'Starting nginx ...'
|
||||
exec s6-setuidgid "$PUID:$PGID" nginx
|
||||
|
@ -3,7 +3,7 @@
|
||||
|
||||
set -e
|
||||
|
||||
. /bin/common.sh
|
||||
. /usr/bin/common.sh
|
||||
|
||||
if [ "$(id -u)" != "0" ]; then
|
||||
log_fatal "This docker container must be run as root, do not specify a user.\nYou can specify PUID and PGID env vars to run processes as that user and group after initialization."
|
||||
|
@ -24,4 +24,5 @@ chown -R "$PUID:$PGID" /etc/nginx/nginx.conf
|
||||
chown -R "$PUID:$PGID" /etc/nginx/conf.d
|
||||
|
||||
# Prevents errors when installing python certbot plugins when non-root
|
||||
chown -R "$PUID:$PGID" /opt/certbot
|
||||
chown "$PUID:$PGID" /opt/certbot /opt/certbot/bin
|
||||
find /opt/certbot/lib/python*/site-packages -not -user "$PUID" -execdir chown "$PUID:$PGID" {} \+
|
||||
|
@ -12,6 +12,10 @@ export CYAN BLUE YELLOW RED RESET
|
||||
PUID=${PUID:-0}
|
||||
PGID=${PGID:-0}
|
||||
|
||||
# If changing the username and group name below,
|
||||
# ensure all references to this user is also changed.
|
||||
# See docker/rootfs/etc/logrotate.d/nginx-proxy-manager
|
||||
# and docker/rootfs/etc/nginx/nginx.conf
|
||||
NPMUSER=npm
|
||||
NPMGROUP=npm
|
||||
NPMHOME=/tmp/npmuserhome
|
Reference in New Issue
Block a user