[GH-ISSUE #2976] Pocketbase health check breaks website #11050

Closed
opened 2026-05-06 15:44:16 -05:00 by GiteaMirror · 5 comments
Owner

Originally created by @Dennis4720 on GitHub (May 3, 2026).
Original GitHub issue: https://github.com/fosrl/pangolin/issues/2976

Describe the Bug

After making https://github.com/orgs/fosrl/discussions/2975 , I wanted to enable health check for all my websites. I found that enabling this for a Pocketbase instance, which gives 404 on / , breaks the application. It will then return unhealthy and the environment returns no available server.

Environment

  • OS Type & Version: (e.g., Ubuntu 22.04): Ubuntu 24.04
  • Pangolin Version: 1.18.2
  • Gerbil Version: Latest?
  • Traefik Version: Latest?
  • Newt Version: 1.12.3
  • Olm Version: (if applicable)

To Reproduce

Enable health check on pocketbase applicaiton.

Expected Behavior

Not to break the website because / returns 404. That's the app's intended behavior.

Originally created by @Dennis4720 on GitHub (May 3, 2026). Original GitHub issue: https://github.com/fosrl/pangolin/issues/2976 ### Describe the Bug After making https://github.com/orgs/fosrl/discussions/2975 , I wanted to enable health check for all my websites. I found that enabling this for a Pocketbase instance, which gives 404 on / , breaks the application. It will then return unhealthy and the environment returns no available server. ### Environment - OS Type & Version: (e.g., Ubuntu 22.04): Ubuntu 24.04 - Pangolin Version: 1.18.2 - Gerbil Version: Latest? - Traefik Version: Latest? - Newt Version: 1.12.3 - Olm Version: (if applicable) ### To Reproduce Enable health check on pocketbase applicaiton. ### Expected Behavior Not to break the website because / returns 404. That's the app's intended behavior.
Author
Owner

@AstralDestiny commented on GitHub (May 3, 2026):

Break how? Like kills the backend application or pangolin breaks how does it break?

If / returns 404 then put the healthcheck path to a part of the backend that doesn't return a 404 but a 200.

<!-- gh-comment-id:4366106614 --> @AstralDestiny commented on GitHub (May 3, 2026): Break how? Like kills the backend application or pangolin breaks how does it break? If / returns 404 then put the healthcheck path to a part of the backend that doesn't return a 404 but a 200.
Author
Owner

@Dennis4720 commented on GitHub (May 3, 2026):

Once health monitor is enabled on the resource, and / returns 404, the whole application returns :

Image

No matter the path. But indeed adjusting the path to /_ (Pocketbase's admin URL) fixes the problem, the health status is green and the environment works. Is this intended?

<!-- gh-comment-id:4366162130 --> @Dennis4720 commented on GitHub (May 3, 2026): Once health monitor is enabled on the resource, and / returns 404, the whole application returns : <img width="533" height="132" alt="Image" src="https://github.com/user-attachments/assets/dbc62ed4-821d-45e7-ab1a-cbd22ba517d4" /> No matter the path. But indeed adjusting the path to /_ (Pocketbase's admin URL) fixes the problem, the health status is green and the environment works. Is this intended?
Author
Owner

@AstralDestiny commented on GitHub (May 3, 2026):

Yeah if the healthcheck fails then it's not provided to traefik at all just like how it would be if it was given a config from the docker socket or a kv provider. No available server is from traefik saying "All loadbalancer ip's behind me are unhealthy / not online." Though there should be a /api/health on pocketbase

https://doc.traefik.io/traefik/reference/routing-configuration/http/load-balancing/service/#health-check if you want to read more on why traefik does this.

https://pocketbase.io/docs/api-health/#health-check should point your healthcheck there honestly.

<!-- gh-comment-id:4366197473 --> @AstralDestiny commented on GitHub (May 3, 2026): Yeah if the healthcheck fails then it's not provided to traefik at all just like how it would be if it was given a config from the docker socket or a kv provider. No available server is from traefik saying "All loadbalancer ip's behind me are unhealthy / not online." Though there should be a /api/health on pocketbase https://doc.traefik.io/traefik/reference/routing-configuration/http/load-balancing/service/#health-check if you want to read more on why traefik does this. https://pocketbase.io/docs/api-health/#health-check should point your healthcheck there honestly.
Author
Owner

@AstralDestiny commented on GitHub (May 3, 2026):

Anyways always will say if you're getting unhealthy try to visit the service you just did a healthcheck for, If you get redirected you'll likely hit a unhealthy or if you get unrelated garbage then go inspect if it has a healthcheck endpoint or whatnot though if can't find feel free to ask.

<!-- gh-comment-id:4366209132 --> @AstralDestiny commented on GitHub (May 3, 2026): Anyways always will say if you're getting unhealthy try to visit the service you just did a healthcheck for, If you get redirected you'll likely hit a unhealthy or if you get unrelated garbage then go inspect if it has a healthcheck endpoint or whatnot though if can't find feel free to ask.
Author
Owner

@Dennis4720 commented on GitHub (May 3, 2026):

Ohh duhh - that makes sense! Thanks so much for clarifying. That helps.

Cheers!

<!-- gh-comment-id:4366211321 --> @Dennis4720 commented on GitHub (May 3, 2026): Ohh duhh - that makes sense! Thanks so much for clarifying. That helps. Cheers!
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/pangolin#11050