[GH-ISSUE #1051] Container unhealthy after update to 3.5.1 - not working anymore #731

Closed
opened 2026-02-25 23:43:23 +03:00 by kerem · 10 comments
Owner

Originally created by @BeyondVertical on GitHub (Aug 21, 2024).
Original GitHub issue: https://github.com/healthchecks/healthchecks/issues/1051

Hey there,
I just updated the image to the latest version - it is not working anymore at all, sadly, after the update.
I used Postgres 16 before and also tried the pgautoupdate-workflow - without success.
I did not change anything on my side. Can you tell me what is wrong?

Here is the log from the container:

2024-08-21T06:10:15.505897517Z [uWSGI] getting INI configuration from /opt/healthchecks/docker/uwsgi.ini
2024-08-21T06:10:15.506226359Z [uwsgi-static] added check for static-collected/
2024-08-21T06:10:15.506241726Z *** Starting uWSGI 2.0.26 (64bit) on [Wed Aug 21 08:10:15 2024] ***
2024-08-21T06:10:15.506250317Z compiled with version: 12.2.0 on 20 August 2024 10:48:51
2024-08-21T06:10:15.506257372Z os: Linux-6.1.0-23-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.99-1 (2024-07-15)
2024-08-21T06:10:15.506264496Z nodename: 19f00da2bfd8
2024-08-21T06:10:15.506272249Z machine: x86_64
2024-08-21T06:10:15.506279374Z clock source: unix
2024-08-21T06:10:15.506285590Z detected number of CPU cores: 12
2024-08-21T06:10:15.506360886Z current working directory: /opt/healthchecks
2024-08-21T06:10:15.506368639Z detected binary path: /usr/local/bin/uwsgi
2024-08-21T06:10:15.506376182Z !!! no internal routing support, rebuild with pcre support !!!
2024-08-21T06:10:15.506384215Z chdir() to /opt/healthchecks
2024-08-21T06:10:15.506392317Z your memory page size is 4096 bytes
2024-08-21T06:10:15.506400140Z detected max file descriptor number: 10000
2024-08-21T06:10:15.506408103Z !!! no /etc/mime.types file found !!!
2024-08-21T06:10:15.506416065Z lock engine: pthread robust mutexes
2024-08-21T06:10:15.506606539Z thunder lock: enabled
2024-08-21T06:10:15.506765303Z uwsgi socket 0 bound to TCP address :8000 fd 3
2024-08-21T06:10:15.506811542Z Python version: 3.12.5 (main, Aug 13 2024, 01:30:38) [GCC 12.2.0]
2024-08-21T06:10:15.522009804Z Python main interpreter initialized at 0x7fc843ceee18
2024-08-21T06:10:15.522045845Z python threads support enabled
2024-08-21T06:10:15.522053109Z your server socket listen backlog is limited to 100 connections
2024-08-21T06:10:15.522059745Z your mercy for graceful operations on workers is 60 seconds
2024-08-21T06:10:15.522066380Z setting request body buffering size to 16192 bytes
2024-08-21T06:10:15.522423650Z mapped 588920 bytes (575 KB) for 4 cores
2024-08-21T06:10:15.522608117Z *** Operational MODE: preforking ***
2024-08-21T06:10:15.522953513Z running "exec:./manage.py migrate" (pre app)...
2024-08-21T06:10:16.711243191Z Operations to perform:
2024-08-21T06:10:16.711288033Z   Apply all migrations: accounts, admin, api, auth, contenttypes, logs, payments, sessions
2024-08-21T06:10:16.734324932Z Running migrations:
2024-08-21T06:10:16.734350287Z   No migrations to apply.
2024-08-21T06:10:17.853368755Z WSGI app 0 (mountpoint='') ready in 0 seconds on interpreter 0x7fc843ceee18 pid: 1 (default app)
2024-08-21T06:10:17.853402073Z *** uWSGI is running in multiple interpreter mode ***
2024-08-21T06:10:17.853409197Z spawned uWSGI master process (pid: 1)
2024-08-21T06:10:17.856075766Z spawned uWSGI worker 1 (pid: 10, cores: 1)
2024-08-21T06:10:17.858375985Z spawned uWSGI worker 2 (pid: 11, cores: 1)
2024-08-21T06:10:17.860979411Z spawned uWSGI worker 3 (pid: 12, cores: 1)
2024-08-21T06:10:17.863478067Z spawned uWSGI worker 4 (pid: 13, cores: 1)
2024-08-21T06:10:17.868906127Z [uwsgi-daemons] spawning "./manage.py sendalerts --skip-checks" (uid: 999 gid: 999)
2024-08-21T06:10:17.872184420Z [uwsgi-daemons] spawning "./manage.py sendreports --loop --skip-checks" (uid: 999 gid: 999)
2024-08-21T06:10:18.670726259Z sendreports is now running
2024-08-21T06:10:18.705118550Z sendalerts is now running
2024-08-21T06:10:21.119949061Z [pid: 10|app: 0|req: 1/1] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:10:20 2024] GET /api/v3/status/ => generated 143 bytes in 486 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0)
2024-08-21T06:10:26.850352255Z [pid: 11|app: 0|req: 1/2] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:10:26 2024] GET /api/v3/status/ => generated 143 bytes in 561 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0)
2024-08-21T06:10:37.492674362Z [pid: 12|app: 0|req: 1/3] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:10:37 2024] GET /api/v3/status/ => generated 143 bytes in 489 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0)
2024-08-21T06:10:48.110345045Z [pid: 13|app: 0|req: 1/4] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:10:47 2024] GET /api/v3/status/ => generated 143 bytes in 458 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0)
2024-08-21T06:10:58.673232712Z [pid: 10|app: 0|req: 2/5] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:10:58 2024] GET /api/v3/status/ => generated 143 bytes in 423 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0)
2024-08-21T06:11:09.256060241Z [pid: 11|app: 0|req: 2/6] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:11:08 2024] GET /api/v3/status/ => generated 143 bytes in 362 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0)
2024-08-21T06:11:19.773321904Z [pid: 12|app: 0|req: 2/7] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:11:19 2024] GET /api/v3/status/ => generated 143 bytes in 373 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0)
2024-08-21T06:11:30.321427535Z [pid: 13|app: 0|req: 2/8] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:11:29 2024] GET /api/v3/status/ => generated 143 bytes in 381 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0)
2024-08-21T06:11:40.833270988Z [pid: 10|app: 0|req: 3/9] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:11:40 2024] GET /api/v3/status/ => generated 143 bytes in 359 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0)
2024-08-21T06:11:51.360919120Z [pid: 11|app: 0|req: 3/10] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:11:50 2024] GET /api/v3/status/ => generated 143 bytes in 379 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0)
2024-08-21T06:12:01.848615939Z [pid: 12|app: 0|req: 3/11] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:12:01 2024] GET /api/v3/status/ => generated 143 bytes in 335 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0)
2024-08-21T06:12:12.396340695Z [pid: 13|app: 0|req: 3/12] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:12:12 2024] GET /api/v3/status/ => generated 143 bytes in 379 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0)
2024-08-21T06:12:22.933256969Z [pid: 10|app: 0|req: 4/13] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:12:22 2024] GET /api/v3/status/ => generated 143 bytes in 383 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0)
2024-08-21T06:12:33.455285942Z [pid: 11|app: 0|req: 4/14] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:12:33 2024] GET /api/v3/status/ => generated 143 bytes in 365 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0)
2024-08-21T06:12:43.998377926Z [pid: 12|app: 0|req: 4/15] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:12:43 2024] GET /api/v3/status/ => generated 143 bytes in 390 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0)
2024-08-21T06:12:54.571457616Z [pid: 13|app: 0|req: 4/16] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:12:54 2024] GET /api/v3/status/ => generated 143 bytes in 427 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0)
2024-08-21T06:13:05.133589477Z [pid: 10|app: 0|req: 5/17] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:13:04 2024] GET /api/v3/status/ => generated 143 bytes in 429 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0)
2024-08-21T06:13:15.599799180Z [pid: 11|app: 0|req: 5/18] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:13:15 2024] GET /api/v3/status/ => generated 143 bytes in 304 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0)
2024-08-21T06:13:26.146850475Z [pid: 12|app: 0|req: 5/19] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:13:25 2024] GET /api/v3/status/ => generated 143 bytes in 375 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0)
2024-08-21T06:13:36.784208398Z [pid: 13|app: 0|req: 5/20] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:13:36 2024] GET /api/v3/status/ => generated 143 bytes in 483 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0)
2024-08-21T06:13:47.243249374Z [pid: 10|app: 0|req: 6/21] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:13:46 2024] GET /api/v3/status/ => generated 143 bytes in 321 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0)
2024-08-21T06:13:57.755584218Z [pid: 11|app: 0|req: 6/22] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:13:57 2024] GET /api/v3/status/ => generated 143 bytes in 358 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0)
2024-08-21T06:14:08.208849624Z [pid: 12|app: 0|req: 6/23] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:14:07 2024] GET /api/v3/status/ => generated 143 bytes in 340 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0)
2024-08-21T06:14:18.803531519Z [pid: 13|app: 0|req: 6/24] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:14:18 2024] GET /api/v3/status/ => generated 143 bytes in 444 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0)
2024-08-21T06:14:29.410188197Z [pid: 10|app: 0|req: 7/25] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:14:28 2024] GET /api/v3/status/ => generated 143 bytes in 442 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0)
2024-08-21T06:14:39.904799708Z [pid: 11|app: 0|req: 7/26] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:14:39 2024] GET /api/v3/status/ => generated 143 bytes in 339 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0)
2024-08-21T06:14:50.496153379Z [pid: 12|app: 0|req: 7/27] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:14:50 2024] GET /api/v3/status/ => generated 143 bytes in 419 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0)
2024-08-21T06:15:01.020012828Z [pid: 13|app: 0|req: 7/28] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:15:00 2024] GET /api/v3/status/ => generated 143 bytes in 370 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0)
2024-08-21T06:15:11.575402307Z [pid: 10|app: 0|req: 8/29] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:15:11 2024] GET /api/v3/status/ => generated 143 bytes in 391 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0)
2024-08-21T06:15:22.089553286Z [pid: 11|app: 0|req: 8/30] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:15:21 2024] GET /api/v3/status/ => generated 143 bytes in 362 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0)

Thanks for your work and your help!

Originally created by @BeyondVertical on GitHub (Aug 21, 2024). Original GitHub issue: https://github.com/healthchecks/healthchecks/issues/1051 Hey there, I just updated the image to the latest version - it is not working anymore at all, sadly, after the update. I used Postgres 16 before and also tried the pgautoupdate-workflow - without success. I did not change anything on my side. Can you tell me what is wrong? Here is the log from the container: ``` 2024-08-21T06:10:15.505897517Z [uWSGI] getting INI configuration from /opt/healthchecks/docker/uwsgi.ini 2024-08-21T06:10:15.506226359Z [uwsgi-static] added check for static-collected/ 2024-08-21T06:10:15.506241726Z *** Starting uWSGI 2.0.26 (64bit) on [Wed Aug 21 08:10:15 2024] *** 2024-08-21T06:10:15.506250317Z compiled with version: 12.2.0 on 20 August 2024 10:48:51 2024-08-21T06:10:15.506257372Z os: Linux-6.1.0-23-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.99-1 (2024-07-15) 2024-08-21T06:10:15.506264496Z nodename: 19f00da2bfd8 2024-08-21T06:10:15.506272249Z machine: x86_64 2024-08-21T06:10:15.506279374Z clock source: unix 2024-08-21T06:10:15.506285590Z detected number of CPU cores: 12 2024-08-21T06:10:15.506360886Z current working directory: /opt/healthchecks 2024-08-21T06:10:15.506368639Z detected binary path: /usr/local/bin/uwsgi 2024-08-21T06:10:15.506376182Z !!! no internal routing support, rebuild with pcre support !!! 2024-08-21T06:10:15.506384215Z chdir() to /opt/healthchecks 2024-08-21T06:10:15.506392317Z your memory page size is 4096 bytes 2024-08-21T06:10:15.506400140Z detected max file descriptor number: 10000 2024-08-21T06:10:15.506408103Z !!! no /etc/mime.types file found !!! 2024-08-21T06:10:15.506416065Z lock engine: pthread robust mutexes 2024-08-21T06:10:15.506606539Z thunder lock: enabled 2024-08-21T06:10:15.506765303Z uwsgi socket 0 bound to TCP address :8000 fd 3 2024-08-21T06:10:15.506811542Z Python version: 3.12.5 (main, Aug 13 2024, 01:30:38) [GCC 12.2.0] 2024-08-21T06:10:15.522009804Z Python main interpreter initialized at 0x7fc843ceee18 2024-08-21T06:10:15.522045845Z python threads support enabled 2024-08-21T06:10:15.522053109Z your server socket listen backlog is limited to 100 connections 2024-08-21T06:10:15.522059745Z your mercy for graceful operations on workers is 60 seconds 2024-08-21T06:10:15.522066380Z setting request body buffering size to 16192 bytes 2024-08-21T06:10:15.522423650Z mapped 588920 bytes (575 KB) for 4 cores 2024-08-21T06:10:15.522608117Z *** Operational MODE: preforking *** 2024-08-21T06:10:15.522953513Z running "exec:./manage.py migrate" (pre app)... 2024-08-21T06:10:16.711243191Z Operations to perform: 2024-08-21T06:10:16.711288033Z Apply all migrations: accounts, admin, api, auth, contenttypes, logs, payments, sessions 2024-08-21T06:10:16.734324932Z Running migrations: 2024-08-21T06:10:16.734350287Z No migrations to apply. 2024-08-21T06:10:17.853368755Z WSGI app 0 (mountpoint='') ready in 0 seconds on interpreter 0x7fc843ceee18 pid: 1 (default app) 2024-08-21T06:10:17.853402073Z *** uWSGI is running in multiple interpreter mode *** 2024-08-21T06:10:17.853409197Z spawned uWSGI master process (pid: 1) 2024-08-21T06:10:17.856075766Z spawned uWSGI worker 1 (pid: 10, cores: 1) 2024-08-21T06:10:17.858375985Z spawned uWSGI worker 2 (pid: 11, cores: 1) 2024-08-21T06:10:17.860979411Z spawned uWSGI worker 3 (pid: 12, cores: 1) 2024-08-21T06:10:17.863478067Z spawned uWSGI worker 4 (pid: 13, cores: 1) 2024-08-21T06:10:17.868906127Z [uwsgi-daemons] spawning "./manage.py sendalerts --skip-checks" (uid: 999 gid: 999) 2024-08-21T06:10:17.872184420Z [uwsgi-daemons] spawning "./manage.py sendreports --loop --skip-checks" (uid: 999 gid: 999) 2024-08-21T06:10:18.670726259Z sendreports is now running 2024-08-21T06:10:18.705118550Z sendalerts is now running 2024-08-21T06:10:21.119949061Z [pid: 10|app: 0|req: 1/1] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:10:20 2024] GET /api/v3/status/ => generated 143 bytes in 486 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0) 2024-08-21T06:10:26.850352255Z [pid: 11|app: 0|req: 1/2] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:10:26 2024] GET /api/v3/status/ => generated 143 bytes in 561 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0) 2024-08-21T06:10:37.492674362Z [pid: 12|app: 0|req: 1/3] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:10:37 2024] GET /api/v3/status/ => generated 143 bytes in 489 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0) 2024-08-21T06:10:48.110345045Z [pid: 13|app: 0|req: 1/4] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:10:47 2024] GET /api/v3/status/ => generated 143 bytes in 458 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0) 2024-08-21T06:10:58.673232712Z [pid: 10|app: 0|req: 2/5] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:10:58 2024] GET /api/v3/status/ => generated 143 bytes in 423 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0) 2024-08-21T06:11:09.256060241Z [pid: 11|app: 0|req: 2/6] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:11:08 2024] GET /api/v3/status/ => generated 143 bytes in 362 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0) 2024-08-21T06:11:19.773321904Z [pid: 12|app: 0|req: 2/7] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:11:19 2024] GET /api/v3/status/ => generated 143 bytes in 373 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0) 2024-08-21T06:11:30.321427535Z [pid: 13|app: 0|req: 2/8] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:11:29 2024] GET /api/v3/status/ => generated 143 bytes in 381 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0) 2024-08-21T06:11:40.833270988Z [pid: 10|app: 0|req: 3/9] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:11:40 2024] GET /api/v3/status/ => generated 143 bytes in 359 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0) 2024-08-21T06:11:51.360919120Z [pid: 11|app: 0|req: 3/10] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:11:50 2024] GET /api/v3/status/ => generated 143 bytes in 379 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0) 2024-08-21T06:12:01.848615939Z [pid: 12|app: 0|req: 3/11] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:12:01 2024] GET /api/v3/status/ => generated 143 bytes in 335 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0) 2024-08-21T06:12:12.396340695Z [pid: 13|app: 0|req: 3/12] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:12:12 2024] GET /api/v3/status/ => generated 143 bytes in 379 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0) 2024-08-21T06:12:22.933256969Z [pid: 10|app: 0|req: 4/13] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:12:22 2024] GET /api/v3/status/ => generated 143 bytes in 383 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0) 2024-08-21T06:12:33.455285942Z [pid: 11|app: 0|req: 4/14] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:12:33 2024] GET /api/v3/status/ => generated 143 bytes in 365 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0) 2024-08-21T06:12:43.998377926Z [pid: 12|app: 0|req: 4/15] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:12:43 2024] GET /api/v3/status/ => generated 143 bytes in 390 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0) 2024-08-21T06:12:54.571457616Z [pid: 13|app: 0|req: 4/16] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:12:54 2024] GET /api/v3/status/ => generated 143 bytes in 427 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0) 2024-08-21T06:13:05.133589477Z [pid: 10|app: 0|req: 5/17] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:13:04 2024] GET /api/v3/status/ => generated 143 bytes in 429 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0) 2024-08-21T06:13:15.599799180Z [pid: 11|app: 0|req: 5/18] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:13:15 2024] GET /api/v3/status/ => generated 143 bytes in 304 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0) 2024-08-21T06:13:26.146850475Z [pid: 12|app: 0|req: 5/19] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:13:25 2024] GET /api/v3/status/ => generated 143 bytes in 375 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0) 2024-08-21T06:13:36.784208398Z [pid: 13|app: 0|req: 5/20] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:13:36 2024] GET /api/v3/status/ => generated 143 bytes in 483 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0) 2024-08-21T06:13:47.243249374Z [pid: 10|app: 0|req: 6/21] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:13:46 2024] GET /api/v3/status/ => generated 143 bytes in 321 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0) 2024-08-21T06:13:57.755584218Z [pid: 11|app: 0|req: 6/22] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:13:57 2024] GET /api/v3/status/ => generated 143 bytes in 358 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0) 2024-08-21T06:14:08.208849624Z [pid: 12|app: 0|req: 6/23] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:14:07 2024] GET /api/v3/status/ => generated 143 bytes in 340 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0) 2024-08-21T06:14:18.803531519Z [pid: 13|app: 0|req: 6/24] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:14:18 2024] GET /api/v3/status/ => generated 143 bytes in 444 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0) 2024-08-21T06:14:29.410188197Z [pid: 10|app: 0|req: 7/25] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:14:28 2024] GET /api/v3/status/ => generated 143 bytes in 442 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0) 2024-08-21T06:14:39.904799708Z [pid: 11|app: 0|req: 7/26] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:14:39 2024] GET /api/v3/status/ => generated 143 bytes in 339 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0) 2024-08-21T06:14:50.496153379Z [pid: 12|app: 0|req: 7/27] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:14:50 2024] GET /api/v3/status/ => generated 143 bytes in 419 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0) 2024-08-21T06:15:01.020012828Z [pid: 13|app: 0|req: 7/28] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:15:00 2024] GET /api/v3/status/ => generated 143 bytes in 370 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0) 2024-08-21T06:15:11.575402307Z [pid: 10|app: 0|req: 8/29] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:15:11 2024] GET /api/v3/status/ => generated 143 bytes in 391 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0) 2024-08-21T06:15:22.089553286Z [pid: 11|app: 0|req: 8/30] 127.0.0.1 () {26 vars in 327 bytes} [Wed Aug 21 08:15:21 2024] GET /api/v3/status/ => generated 143 bytes in 362 msecs (HTTP/1.1 400) 4 headers in 172 bytes (1 switches on core 0) ``` Thanks for your work and your help!
kerem closed this issue 2026-02-25 23:43:23 +03:00
Author
Owner

@mariusc23 commented on GitHub (Aug 21, 2024):

Ran into the same issue with Traefik in front. After setting DEBUG=True I see this:

healthchecks           | Invalid HTTP_HOST header: 'localhost:8000'. You may need to add 'localhost' to ALLOWED_HOSTS.
healthchecks           | Traceback (most recent call last):
healthchecks           |   File "/usr/local/lib/python3.12/site-packages/django/core/handlers/exception.py", line 55, in inner
healthchecks           |     response = get_response(request)
healthchecks           |                ^^^^^^^^^^^^^^^^^^^^^
healthchecks           |   File "/usr/local/lib/python3.12/site-packages/django/utils/deprecation.py", line 128, in __call__
healthchecks           |     response = self.process_request(request)
healthchecks           |                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
healthchecks           |   File "/usr/local/lib/python3.12/site-packages/django/middleware/common.py", line 48, in process_request
healthchecks           |     host = request.get_host()
healthchecks           |            ^^^^^^^^^^^^^^^^^^
healthchecks           |   File "/usr/local/lib/python3.12/site-packages/django/http/request.py", line 151, in get_host
healthchecks           |     raise DisallowedHost(msg)
healthchecks           | django.core.exceptions.DisallowedHost: Invalid HTTP_HOST header: 'localhost:8000'. You may need to add 'localhost' to ALLOWED_HOSTS.

Adding localhost to ALLOWED_HOSTS fixes the issue.

<!-- gh-comment-id:2301242503 --> @mariusc23 commented on GitHub (Aug 21, 2024): Ran into the same issue with Traefik in front. After setting `DEBUG=True` I see this: ``` healthchecks | Invalid HTTP_HOST header: 'localhost:8000'. You may need to add 'localhost' to ALLOWED_HOSTS. healthchecks | Traceback (most recent call last): healthchecks | File "/usr/local/lib/python3.12/site-packages/django/core/handlers/exception.py", line 55, in inner healthchecks | response = get_response(request) healthchecks | ^^^^^^^^^^^^^^^^^^^^^ healthchecks | File "/usr/local/lib/python3.12/site-packages/django/utils/deprecation.py", line 128, in __call__ healthchecks | response = self.process_request(request) healthchecks | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ healthchecks | File "/usr/local/lib/python3.12/site-packages/django/middleware/common.py", line 48, in process_request healthchecks | host = request.get_host() healthchecks | ^^^^^^^^^^^^^^^^^^ healthchecks | File "/usr/local/lib/python3.12/site-packages/django/http/request.py", line 151, in get_host healthchecks | raise DisallowedHost(msg) healthchecks | django.core.exceptions.DisallowedHost: Invalid HTTP_HOST header: 'localhost:8000'. You may need to add 'localhost' to ALLOWED_HOSTS. ``` Adding `localhost` to `ALLOWED_HOSTS` fixes the issue.
Author
Owner

@BeyondVertical commented on GitHub (Aug 21, 2024):

That is exactly my setup, @mariusc23. Will have a look at this later on. Where would I put the localhost, traefik config?

<!-- gh-comment-id:2301337135 --> @BeyondVertical commented on GitHub (Aug 21, 2024): That is exactly my setup, @mariusc23. Will have a look at this later on. Where would I put the localhost, traefik config?
Author
Owner

@huyz commented on GitHub (Aug 21, 2024):

My error was somewhat different. I ran the pgautoupdate instructions and it seems to have worked, but when I try to bring up the DB, I still get DETAIL: The data directory was initialized by PostgreSQL version 12, which is not compatible with this version 16.4 strangely.

My workaround was to change my docker-compose.yml to reference the image pgautoupgrade/pgautoupgrade:16-bookworm rather than postgres:16 since pgautoupgrade is supposed to be a drop-in replacement.

<!-- gh-comment-id:2301744401 --> @huyz commented on GitHub (Aug 21, 2024): My error was somewhat different. I ran the `pgautoupdate` instructions and it seems to have worked, but when I try to bring up the DB, I still get `DETAIL: The data directory was initialized by PostgreSQL version 12, which is not compatible with this version 16.4` strangely. My workaround was to change my docker-compose.yml to reference the image `pgautoupgrade/pgautoupgrade:16-bookworm` rather than `postgres:16` since `pgautoupgrade` is supposed to be a drop-in replacement.
Author
Owner

@techsolo12 commented on GitHub (Aug 21, 2024):

I ran a setup with MariaDB 10.8 and Traffik and got the same error. After adding ,localhost to my normal hc address in ALLOWED_HOSTS the stack work again.

<!-- gh-comment-id:2301770726 --> @techsolo12 commented on GitHub (Aug 21, 2024): I ran a setup with MariaDB 10.8 and Traffik and got the same error. After adding `,localhost` to my normal hc address in `ALLOWED_HOSTS` the stack work again.
Author
Owner

@cuu508 commented on GitHub (Aug 21, 2024):

I added a HEALTHCHECK instruction in the Dockerfile here: github.com/healthchecks/healthchecks@8fed685f12

The healthcheck script calls http://localhost:8000/api/v3/status/, which fails if localhost is not in ALLOWED_HOSTS. This is my error, I didn't think of ALLOWED_HOSTS while working on this. Not yet sure what the best fix would be.

<!-- gh-comment-id:2301809496 --> @cuu508 commented on GitHub (Aug 21, 2024): I added a HEALTHCHECK instruction in the Dockerfile here: https://github.com/healthchecks/healthchecks/commit/8fed685f129f1eb1d66ca001f7e4872ac5f2f04d The healthcheck script calls `http://localhost:8000/api/v3/status/`, which fails if `localhost` is not in `ALLOWED_HOSTS`. This is my error, I didn't think of ALLOWED_HOSTS while working on this. Not yet sure what the best fix would be.
Author
Owner

@BeyondVertical commented on GitHub (Aug 21, 2024):

Make it variable and configurable via Environment variable, so that the default is localhost and if someone needs another hostname, we could set the variable?

<!-- gh-comment-id:2301839433 --> @BeyondVertical commented on GitHub (Aug 21, 2024): Make it variable and configurable via Environment variable, so that the default is localhost and if someone needs another hostname, we could set the variable?
Author
Owner

@cuu508 commented on GitHub (Aug 21, 2024):

I pushed a fix, and released v3.5.2 (image is up on Docker Hub).

The fix is to take the first value from the ALLOWED_HOSTS setting, and use it in the HTTP Host header when making requests to http://localhost:8000/api/v3/status/.

@BeyondVertical, @techsolo12 if you get a chance to test, please let me know if it works for you. If you added localhost to ALLOWED_HOSTS to make v3.5.1 work, please try removing it – it should work without it same as v3.4 did.

<!-- gh-comment-id:2302061966 --> @cuu508 commented on GitHub (Aug 21, 2024): I pushed a fix, and released v3.5.2 (image is up on Docker Hub). The fix is to take the first value from the ALLOWED_HOSTS setting, and use it in the HTTP Host header when making requests to `http://localhost:8000/api/v3/status/`. @BeyondVertical, @techsolo12 if you get a chance to test, please let me know if it works for you. If you added `localhost` to `ALLOWED_HOSTS` to make v3.5.1 work, please try removing it – it should work without it same as v3.4 did.
Author
Owner

@techsolo12 commented on GitHub (Aug 21, 2024):

@cuu508 Thank you for the fix. I removed the localhost, pull the new image and for now it seems to work. I will monitor it for some days.

<!-- gh-comment-id:2302144314 --> @techsolo12 commented on GitHub (Aug 21, 2024): @cuu508 Thank you for the fix. I removed the `localhost`, pull the new image and for now it seems to work. I will monitor it for some days.
Author
Owner

@etho201 commented on GitHub (Aug 21, 2024):

I can confirm v3.5.2 fixes the issue.

<!-- gh-comment-id:2302364853 --> @etho201 commented on GitHub (Aug 21, 2024): I can confirm `v3.5.2` fixes the issue.
Author
Owner

@BeyondVertical commented on GitHub (Aug 21, 2024):

Yeah, confirmed. Thanks for this fix. I did not need to change anything - and couldn't because I wasn't at home all day. So, thanks! :)

<!-- gh-comment-id:2302965350 --> @BeyondVertical commented on GitHub (Aug 21, 2024): Yeah, confirmed. Thanks for this fix. I did not need to change anything - and couldn't because I wasn't at home all day. So, thanks! :)
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/healthchecks#731
No description provided.