Commit Graph

12 Commits

Author SHA1 Message Date
Michael Martin
c3ac102eba Enhancement: speed-up docker container startup (#11134)
This alters the retry/backoff logic in the init-wait-for-db script to be more
optimistic about database availability. During regular deployment and
operations of paperless-ngx, it's common to restart the application server with
the database instance already running, so we should optimize for this case.

Instead of unconditionally delaying 5 seconds between each connection attempt,
start with a minimum delay of 1 second and increase the delay linearly with
each attempt, maxing out at 10 seconds. This makes the retry count-based
failure mode less practical, so instead we just use a timeout-based approach.*

*NOTE: the original implementation would have an effective timeout of 25s. This
alters the behavior to 60s.

Additionally, this removes an unnecessary 5s delay that was injected in the
postgres case. The script uses a more comprehensive connection check for
postgres than it does mariadb, so if anything this 5s delay after getting an
"ok" response from the DB was extra unnecessary in the postgres case.
2025-11-17 13:11:49 -08:00
shamoon
cc5ba71f06 Chore: remove spaces from run log 2025-06-17 16:02:45 -07:00
Trenton H
c83b0bfca6 Fix: Trim off the path portion so the comparision can properly skip (#9839) 2025-05-01 13:50:25 -07:00
Trenton H
ab8c75958d Fix: Adds better handling during folder checking/creation/permissions for non-root (#9616)
* Adds better handling during folder checking/creation/permissions for when the image is running as non-root

* Prefers the long options to commands
2025-04-14 15:51:57 +00:00
Trenton H
e2860ed36d Fix: Explicitly set the HOME environment variable for running as root at startup (#9643)
* Explicitly set the HOME environment for the migrations to fix issue with certificates

* Defines the HOME globally when we're running as root for startup
2025-04-14 15:21:45 +00:00
Trenton H
0fb55f3ae8 Fix: Run migration lock as the correct user (#9604) 2025-04-09 21:15:38 +00:00
Trenton H
78822f6121 Fix: Adds a warning to the user if their secret file includes a trailing newline (#9601) 2025-04-09 21:05:26 +00:00
Trenton H
6e694ad9ff Switch to using uvloop and upgrade granian for some ASGI fixes (#9494) 2025-03-25 21:41:29 -07:00
Trenton H
9944f81512 Fix: Allow setting of other Granian options (#9360) 2025-03-11 17:33:56 +00:00
Trenton H
654c9ca273 Feature: Switch webserver to granian (#9218)
Co-authored-by: shamoon <4887959+shamoon@users.noreply.github.com>
2025-02-28 19:37:45 +00:00
shamoon
a548c32c1f Enhancement: allow disabling the filesystem consumer (#9199) 2025-02-23 13:52:41 -08:00
Trenton H
880f08599a Transitions the Docker image to use s6 and s6-overlay for process supervision instead of supervisord (#8886) 2025-02-07 11:25:54 -08:00