Add support for --env-file= flag for node 20 in nodeArguments
#3293
Unanswered
torbjornvatn
asked this question in
Q&A
Replies: 2 comments 1 reply
|
However with worker threads, not all arguments have an effect. Some values are inherited from the main process. My guess is that this is the case for Running the following should work: NODE_OPTIONS="--env-file=.env" npx avaThis way, the env vars are added to the main AVA process and should be inherited by the worker threads. See also nodejs/node#37410. |
0 replies
|
Hmm, seems like that's not allowed actually
I've solved it by falling back to Could it be an alternative to add an |
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Please provide details about:
I was hoping that I could add a config like:
and get access to the environments loaded by Node from that file.
--env-fileconfig
Even though ava accepts the nodeArguments config above the result of running:
in a test is this:
Would it be possible to make ava pass this on to node so it gets loaded as environment variables
All reactions