mirror of
https://github.com/PostHog/posthog.git
synced 2024-11-25 11:17:50 +01:00
fix: Split healthcheck to separate nginx unit app (#20917)
Split healthcheck to separate nginx unit app When posthog is under load the healthcheck can stop responding. Split it off into a separate app so it has a dedicated thread to handle it
This commit is contained in:
parent
8b92cd1c62
commit
466c417e2b
28
unit.json
28
unit.json
@ -6,7 +6,7 @@
|
||||
},
|
||||
"listeners": {
|
||||
"*:8000": {
|
||||
"pass": "applications/posthog"
|
||||
"pass": "routes/posthog"
|
||||
},
|
||||
"*:8001": {
|
||||
"pass": "routes/metrics"
|
||||
@ -16,6 +16,21 @@
|
||||
}
|
||||
},
|
||||
"routes": {
|
||||
"posthog": [
|
||||
{
|
||||
"match": {
|
||||
"uri": ["/healthz"]
|
||||
},
|
||||
"action": {
|
||||
"pass": "applications/posthog-health"
|
||||
}
|
||||
},
|
||||
{
|
||||
"action": {
|
||||
"pass": "applications/posthog"
|
||||
}
|
||||
}
|
||||
],
|
||||
"metrics": [
|
||||
{
|
||||
"match": {
|
||||
@ -38,6 +53,17 @@
|
||||
]
|
||||
},
|
||||
"applications": {
|
||||
"posthog-health": {
|
||||
"type": "python 3.10",
|
||||
"processes": 1,
|
||||
"working_directory": "/code",
|
||||
"path": ".",
|
||||
"module": "posthog.wsgi",
|
||||
"user": "nobody",
|
||||
"limits": {
|
||||
"requests": 5000
|
||||
}
|
||||
},
|
||||
"posthog": {
|
||||
"type": "python 3.10",
|
||||
"processes": 4,
|
||||
|
Loading…
Reference in New Issue
Block a user