optimize set nginx conf env#2174
Conversation
| event: | ||
| worker_connections: 10620 | ||
| envs: | ||
| - TEST |
There was a problem hiding this comment.
We can add APISIX_PROFILE as the default.
There was a problem hiding this comment.
I changed my idea. We should always include APISIX_PROFILE.
Since the TEST is useless now, we should comment it out and just let it as an example.
| event: | ||
| worker_connections: 10620 | ||
| envs: | ||
| - APISIX_PROFILE |
There was a problem hiding this comment.
Since default configure can be overridden by the user, I think we should always include APISIX_PROFILE in the nginx.conf template. Otherwise, APISIX_PROFILE might be lost by mistake. We can leave a comment here as example.
There was a problem hiding this comment.
From the definition of APISIX_PROFILE, you are right. But I think this configuration should be defined in the configuration file instead of environment variables. I think can use the environment variable definition part of the configuration. When there is a corresponding environment variable definition, the environment variable is preferred
There was a problem hiding this comment.
the above are my thoughts. i modifyd a version first will not cover APISIX_PROFILE
What this PR does / why we need it:
I need to get env variables in the plugin so I need to set nginx conf environment variables
Pre-submission checklist: