Closed technosophos closed 3 years ago
Right now, if you want to pass environment variables to the guest module, you do so on the CLI like this:
$ wagi -e FOO=1 -e BAR=2
We could support a Docker-style (or Heroku style) .env file that had a simple format like this:
.env
FOO=1 BAR=2
I think this could be done simply with an existing Rust crate.
I think the default behavior would be to try to load a $(PWD)/.env file, but with a CLI flag to override. Though if we are reluctant to load by default, we could just add an --env-file=$PATH option.
$(PWD)/.env
--env-file=$PATH
As @bacongobbler pointed out in a conversation, it could be unclear what should load a .env. So maybe an explicit flag is the best way to start.
Right now, if you want to pass environment variables to the guest module, you do so on the CLI like this:
We could support a Docker-style (or Heroku style)
.env
file that had a simple format like this:I think this could be done simply with an existing Rust crate.
I think the default behavior would be to try to load a
$(PWD)/.env
file, but with a CLI flag to override. Though if we are reluctant to load by default, we could just add an--env-file=$PATH
option.