-
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Configure nginx to run as an unprivileged user (#75)
* Update npm * Add default nginx.conf * Log starting
- Loading branch information
Showing
3 changed files
with
31 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
worker_processes auto; | ||
pid /tmp/nginx.pid; | ||
error_log /tmp/error.log; | ||
include /etc/nginx/modules-enabled/*.conf; | ||
|
||
events { | ||
worker_connections 768; | ||
} | ||
|
||
http { | ||
client_body_temp_path /tmp/client_temp; | ||
proxy_temp_path /tmp/proxy_temp_path; | ||
fastcgi_temp_path /tmp/fastcgi_temp; | ||
uwsgi_temp_path /tmp/uwsgi_temp; | ||
scgi_temp_path /tmp/scgi_temp; | ||
sendfile on; | ||
tcp_nopush on; | ||
types_hash_max_size 2048; | ||
include /etc/nginx/mime.types; | ||
default_type application/octet-stream; | ||
ssl_protocols TLSv1 TLSv1.1 TLSv1.2 TLSv1.3; # Dropping SSLv3, ref: POODLE | ||
ssl_prefer_server_ciphers on; | ||
access_log /tmp/access.log; | ||
gzip on; | ||
include /etc/nginx/conf.d/*.conf; | ||
include /etc/nginx/sites-enabled/*; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
#!/command/with-contenv bashio | ||
# -*- bash -*- | ||
# shellcheck shell=bash | ||
mkdir /run/nginx | ||
|
||
bashio::log.info "Starting NGINX..." | ||
exec nginx -g 'daemon off;error_log /proc/1/fd/1 error;' |