Skip to content

Commit ca75fb5

Browse files
authored
Merge pull request jonaswinkler#1358 from paperless-ngx/bugfix-ip-bind-addr
Bugfix: Allow webserver bind address to be configured
2 parents cb7e6f8 + ada8516 commit ca75fb5

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

docs/configuration.rst

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -808,6 +808,13 @@ PAPERLESS_WEBSERVER_WORKERS=<num>
808808

809809
Defaults to 1.
810810

811+
PAPERLESS_BIND_ADDR=<ip address>
812+
The IP address the webserver will listen on inside the container. There are
813+
special setups where you may need to configure this value to restrict the
814+
Ip address or interface the webserver listens on.
815+
816+
Defaults to [::], meaning all interfaces, including IPv6.
817+
811818
PAPERLESS_PORT=<port>
812819
The port number the webserver will listen on inside the container. There are
813820
special setups where you may need this to avoid collisions with other

gunicorn.conf.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import os
22

3-
bind = f'[::]:{os.getenv("PAPERLESS_PORT", 8000)}'
3+
bind = f'{os.getenv("PAPERLESS_BIND_ADDR", "[::]")}:{os.getenv("PAPERLESS_PORT", 8000)}'
44
workers = int(os.getenv("PAPERLESS_WEBSERVER_WORKERS", 1))
55
worker_class = "paperless.workers.ConfigurableWorker"
66
timeout = 120

0 commit comments

Comments
 (0)