Thanks for posting the solution above 🙂
Deadpikle I am doing a long-running operation in a PHP app
Just a heads-up that you can bypass the reverse proxy if you want to, by referencing your app directly by its port. This is the primary reason for allowing non-auto port numbers — so you can know for sure what it will always be available at. Not sure if this is appropriate in your use-case though.
I should clarify that the ability to override the system stack's config does work as described in your solution above, but carries one significant limitation at present, hence me not putting it in the docs at this point. The limitation is this: only the last-started stack's system overrides will be used.
So for example, say I have two stacks, where only stack A provides system stack overrides; if I start up stack A, the system stack is rebuilt using the overrides in stack A — all good at this point. If I then start stack B, the system stack is rebuilt using any overrides in stack B, of which there are none. At this point stack A's overrides have been removed.
Two things come to mind:
a) I do think at some point I should add code so the system stack compiles the overrides found in all currently-starting/started stacks. Although then there's the question of precedence. The best way to handle this whole topic is a little undefined in my mind at present — tbh I was rather hoping nobody would need to override the system stack, although I personally do need to (lol). So I'm definitely interested in others' thoughts.
b) I wonder if the default keepalive_timeout
could/should be made arbitrarily large eg 5 minutes. What do you think?
tldr; if your system-level overrides disappear, restart the stack that defines them and they will be recompiled into the system stack.