0

Is there any way when running nginx from command line to have all environment variables defined at execution automatically propagate to FPM? Ideally without having to hard-code them in any config files?

I'm hoping to see if there's a solution that doesn't involve adding any tools, I'm aware of hacks/workarounds using sed, although my hope is to not add complexity.

  • 3
    This is not done by default for security reasons. You should very carefully consider whatever the problem is you're trying to solve; there is almost certainly a better way. – Michael Hampton Feb 01 '15 at 02:42
  • I could see that, although when running inside a docker container, the only env I have set are things pertaining to my hosting configuration. – Alexander Trauzzi Feb 01 '15 at 14:44
  • The content of this article will help you. https://gist.github.com/CMCDragonkai/50739cd498d2ae5d2075e25528bf8751 – Maycon Vinicius Jun 04 '18 at 13:38

0 Answers0