Skip to content
This repository was archived by the owner on Apr 8, 2020. It is now read-only.

Setting node's NODE_ENV based off of ASPNETCORE_ENVIRONMENT? #230

Closed
pauldotknopf opened this issue Jul 30, 2016 · 2 comments
Closed

Setting node's NODE_ENV based off of ASPNETCORE_ENVIRONMENT? #230

pauldotknopf opened this issue Jul 30, 2016 · 2 comments

Comments

@pauldotknopf
Copy link
Contributor

Or, allow us to manually specific environment variables for the node instances ourselves.

@pauldotknopf pauldotknopf changed the title Setting node's NODE_ENV based off of ASPNETCORE_ENVIRONMENT? Setting node's NODE_ENV based off of ASPNETCORE_ENVIRONMENT? Jul 30, 2016
@SteveSandersonMS
Copy link
Member

Yes, this sounds good! If you want to do a PR that would be great, otherwise I'll get to this within the next couple of weeks.

SteveSandersonMS added a commit that referenced this issue Aug 16, 2016
…us auto-populate NODE_ENV based on IHostingEnvironment when possible. Fixes #230
@SteveSandersonMS
Copy link
Member

Now implemented. I'll publish updated packages soon.

I've also added an EnvironmentVariables property to NodeServicesOptions you can use to pass arbitrary env vars.

If you just want NODE_ENV set to development/production based on your ASP.NET app's hosting environment, you don't have to do anything - this now happens automatically.

geirsagberg added a commit to geirsagberg/JavaScriptServices that referenced this issue Aug 17, 2016
* upstream/dev:
  Add ability to configure environment variables for Node instances, plus auto-populate NODE_ENV based on IHostingEnvironment when possible. Fixes aspnet#230
  Rename PrimeCache to PrimeCacheAsync (keeping older name as obsolete overload). Fixes aspnet#246.
  Prerenderer now passes original (unescaped) URL to Node - fixes aspnet#250
  In WebpackDevMiddleware, allow configuration of ProjectPath (implements aspnet#262)
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants