Request opinions on alternate erlang config formats

Tristan Sloughter t@REDACTED
Sun Apr 5 19:54:01 CEST 2020


I've always been meaning to try a method of shipping a little binary with the release that takes in config in some other format and outputs sys.config -- just using the relx start script hooks to run it before startup.

Not sure how small you can get a Rust compiled program to these days but if it was doable to strip it down to <1 MB I'd see that as a viable option -- could read in toml, yaml, json, etc and write out an Erlang term file (pretty sure there is a crate for that already) sys.config.

Other ideas have been extending Cue (https://cuelang.org/) or Dhall (https://dhall-lang.org/) or Starlark (https://github.com/google/starlark-go) to output Erlang term files.

But with my work none of this has materialized because its unneeded and I'm satisfied with OS environment variable replacement in sys.config.src with the environment variables populated by K8s -- so I haven't tried to create anything more complicated like above.

Tristan



More information about the erlang-questions mailing list