Skip to content
Ofer Skolsky edited this page Oct 5, 2020 · 1 revision

Special notes on JSON

{
    "github": {
        "token": ${GITHUB_TOKEN},
        "configAsCode": "cx.configuration"
    },
    "ast": {
        "apiUrl": "http://this.is.just.an.example",
        "token": ${AST_TOKEN},
        "preset": true,
        "incremental": false
    }
}

unlike normal json files, the configuration is HOCON and can have variables,
The variables are resoved, if the value is not quated as follow:

  • ${XXX} - will be resolved to the system environment variable with the name XXX. ex. ${AST_TOKEN}
  • ${path.in.config} - will be resolved to the value inside the configuration. ex. ${ast.preset} is true

note: if the value is quated, the variables will not be resolved. ex. "this is a normal text with special characters like $ and { "

Clone this wiki locally