Skip to content

Commit 8bcf041

Browse files
committed
docs: clarify Bake environment variable override behavior
Signed-off-by: rishabh <rishank69@gmail.com> docs: address review feedback on bake env lookup Signed-off-by: rishabh <rishank69@gmail.com>
1 parent c461e70 commit 8bcf041

1 file changed

Lines changed: 8 additions & 2 deletions

File tree

docs/bake-reference.md

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1350,11 +1350,17 @@ to define them.
13501350

13511351
### Use environment variable as default
13521352

1353-
You can set a Bake variable to use the value of an environment variable as a default value:
1353+
If an environment variable exists with the same name as a declared Bake
1354+
variable, Bake uses that environment variable value instead of the declared
1355+
default.
1356+
1357+
To disable this environment-based variable lookup, set
1358+
`BUILDX_BAKE_DISABLE_VARS_ENV_LOOKUP=1`.
1359+
13541360

13551361
```hcl
13561362
variable "HOME" {
1357-
default = "$HOME"
1363+
default = "/root"
13581364
}
13591365
```
13601366

0 commit comments

Comments
 (0)