- Notifications
You must be signed in to change notification settings - Fork22
Description
Resource Name
coder_env
Description
This feature would introduce a new resource,coder_env
, to the Coder Terraform provider, allowing users to inject environment variables dynamically into workspaces at creation and update.
Expected Behavior
- Enable defining environment variables in the Terraform configuration file using
coder_env
. - Inject environment variables into the workspace specified by the
agent_id
.
Use Case
Automating workspace setups to include necessary environment variables is essential for preparing development environments with all the configurations needed for applications and services to function correctly. An example use case is configuring go to use Artifactory, which requires settingGOPROXY
.
Example Configuration
Single variable
resource"coder_env""example" {agent_id=coder_agent.example.idname="VAR1"value="Value1"}
Multiple variables
resource"coder_env""example" {agent_id=coder_agent.example.iditem {name="VAR1"value="Value1" }item {name="VAR2"value="Value2" }
or
resource"coder_env""example" {agent_id=coder_agent.example.idenv={VAR1="value1"VAR2="value2" }}
Metadata
Metadata
Assignees
Labels
No labels