Skip to content

[ANCM] Add switch to prefer env over web.config #19746

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Mar 11, 2020
Merged

Conversation

BrennanConroy
Copy link
Member

Fixes #19450

@@ -13,6 +13,7 @@
#define ASPNETCORE_IIS_AUTH_BASIC L"basic;"
#define ASPNETCORE_IIS_AUTH_ANONYMOUS L"anonymous;"
#define ASPNETCORE_IIS_AUTH_NONE L"none"
#define ANCM_PREFER_ENVIRONMENT_VARIABLES_ENV_STR L"ANCM_PREFER_ENVIRONMENT_VARIABLES"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why ANCM instead of ASPNETCORE_ANCM like in ASPNETCORE_ANCM_HTTPS_PORT?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤷‍♂ @jkotalik @anurse
Let the naming bikeshed commence!

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This environment variable is only used by ANCM. All other environment variables are eventually used by managed code, while this is exclusively used by ANCM.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm fine with this name for now.

Copy link
Contributor

@analogrelay analogrelay Mar 11, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We use ANCM for other variables. For example ANCM_HTTPS_PORT.

Seems reasonable to keep this name consistent.

Copy link
Contributor

@analogrelay analogrelay Mar 11, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why ANCM instead of ASPNETCORE_ANCM like in ASPNETCORE_ANCM_HTTPS_PORT?

Ah, and the reason for the ASPNETCORE_ prefix in ANCM_HTTPS_PORT is the fact that it's read out of config. This is directly read as an env var. I could go either way I suppose 🤷‍♀

@BrennanConroy BrennanConroy merged commit fdaa334 into master Mar 11, 2020
@BrennanConroy BrennanConroy deleted the brecon/env branch March 11, 2020 22:53
@amcasey amcasey added area-networking Includes servers, yarp, json patch, bedrock, websockets, http client factory, and http abstractions and removed area-runtime labels Jun 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-networking Includes servers, yarp, json patch, bedrock, websockets, http client factory, and http abstractions
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add switch to allow ANCM to prefer local environment variables over web.config environment variables.
5 participants