Commit Graph

10 Commits (0269388aa77d1c32420c0f7227e1325bac1efbd2)

Author SHA1 Message Date
Tõnis Tiigi 42448c5f37
Merge pull request #280 from vanstee/hcl-json-support
Support parsing json config with hcl v2
5 years ago
Patrick Van Stee 355261e49e
Parse bake config as hcl falling back to json
Signed-off-by: Patrick Van Stee <patrick@vanstee.me>
5 years ago
Patrick Van Stee 340686a383
Support parsing json config with hcl v2
Signed-off-by: Patrick Van Stee <patrick@vanstee.me>
5 years ago
Brian Goff 1ad87c6ba6 Update go-cty to pull in more stdlib funcs.
I needed "split" specifically so I can do something like:

```hcl
variable PLATFORMS {
  default = "linux/amd64"
}

target foo {
  platforms = split(",", "${PLATFORMS}")
  # other stuff
}
```

Where the existing "csvdecode" does not work for this because it parses
the string into a list of objects instead of a list of strings.

I went ahead and just added all the available new functions.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
5 years ago
Patrick Van Stee 870b38837b Allow for user defined functions
Signed-off-by: Patrick Van Stee <patrick@vanstee.me>
5 years ago
Patrick Van Stee f10d8dab5e Define variables as blocks with defaults
Signed-off-by: Patrick Van Stee <patrick@vanstee.me>
5 years ago
Patrick Van Stee 5185d534bc Include go-cty stdlib functions in HCL file scope
Signed-off-by: Patrick Van Stee <patrick@vanstee.me>
5 years ago
Patrick Van Stee a520de447e Provide current env as variables in eval context
Signed-off-by: Patrick Van Stee <patrick@vanstee.me>
5 years ago
Patrick Van Stee 4121ae50b5 Modify parsing functions and config structs to accept hcl changes
Signed-off-by: Patrick Van Stee <patrick@vanstee.me>
5 years ago
Tonis Tiigi a932d52e35 bake: initial implementation
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
6 years ago