Fixes #26775: Use empty default for OIDC_CUSTOM_PARAMS to fix Compose brace-parsing#26965
Conversation
|
Hi there 👋 Thanks for your contribution! The OpenMetadata team will review the PR shortly! Once it has been labeled as Let us know if you need any help! |
There was a problem hiding this comment.
Pull request overview
This PR fixes a Docker Compose interpolation edge case that could generate malformed YAML for customParams in OpenMetadata OIDC config when OIDC_CUSTOM_PARAMS is unset (notably in some Compose-compatible runtimes like Podman Compose).
Changes:
- Quote the default value for
OIDC_CUSTOM_PARAMSin Compose interpolation from${OIDC_CUSTOM_PARAMS:-{}}to${OIDC_CUSTOM_PARAMS:-"{}"}. - Apply the same fix consistently across quickstart, production, and development Compose files.
Reviewed changes
Copilot reviewed 8 out of 8 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
docker/docker-compose-quickstart/docker-compose.yml |
Quotes OIDC_CUSTOM_PARAMS default to avoid brace-parsing ambiguity in Compose interpolation. |
docker/docker-compose-quickstart/docker-compose-postgres.yml |
Same quoting fix for the Postgres quickstart Compose. |
docker/docker-compose-quickstart/docker-compose-rdf.yml |
Same quoting fix for the RDF quickstart Compose. |
docker/docker-compose-openmetadata/docker-compose-openmetadata.yml |
Same quoting fix for the OpenMetadata Compose bundle. |
docker/development/docker-compose.yml |
Same quoting fix for the development Compose. |
docker/development/docker-compose-postgres.yml |
Same quoting fix for the Postgres development Compose. |
docker/development/docker-compose-gcp.yml |
Same quoting fix for the GCP development Compose. |
docker/development/docker-compose-postgres-fuseki.yml |
Same quoting fix for the Postgres+Fuseki development Compose. |
1f6b0cb to
60195fe
Compare
a7b0ee7 to
8853646
Compare
…o fix Compose brace-parsing
| OIDC_TENANT: ${OIDC_TENANT:-""} | ||
| OIDC_MAX_CLOCK_SKEW: ${OIDC_MAX_CLOCK_SKEW:-""} | ||
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-{}} | ||
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-} |
There was a problem hiding this comment.
OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-} is unquoted. If unset, it can resolve to YAML null (Compose pass-through/omit behavior); if set to {...}, it may be parsed as a YAML map rather than a string. Quote the interpolation or use an explicit empty-string default so the env var is always a string.
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-} | |
| OIDC_CUSTOM_PARAMS: "${OIDC_CUSTOM_PARAMS:-""}" |
| OIDC_TENANT: ${OIDC_TENANT:-""} | ||
| OIDC_MAX_CLOCK_SKEW: ${OIDC_MAX_CLOCK_SKEW:-""} | ||
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-{}} | ||
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-} |
There was a problem hiding this comment.
Same issue as earlier in the file: leaving ${OIDC_CUSTOM_PARAMS:-} unquoted can resolve to YAML null when unset and can be parsed as a YAML map for {...} values. Quote the interpolation or default explicitly to an empty string so the container consistently receives a string.
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-} | |
| OIDC_CUSTOM_PARAMS: "${OIDC_CUSTOM_PARAMS:-""}" |
| OIDC_TENANT: ${OIDC_TENANT:-""} | ||
| OIDC_MAX_CLOCK_SKEW: ${OIDC_MAX_CLOCK_SKEW:-""} | ||
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-{}} | ||
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-} |
There was a problem hiding this comment.
Same issue as earlier in the file: ${OIDC_CUSTOM_PARAMS:-} is unquoted; unset can become YAML null (Compose pass-through/omit), and {...} values can be parsed as YAML maps. Quote the interpolation or use an explicit empty-string default to keep the env var value a string.
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-} | |
| OIDC_CUSTOM_PARAMS: "${OIDC_CUSTOM_PARAMS:-}" |
| OIDC_TENANT: ${OIDC_TENANT:-""} | ||
| OIDC_MAX_CLOCK_SKEW: ${OIDC_MAX_CLOCK_SKEW:-""} | ||
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-{}} | ||
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-} |
There was a problem hiding this comment.
OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-} is unquoted, which can yield YAML null when unset (Compose pass-through/omit semantics) and YAML map typing when set to {...}. Quote the interpolation or default explicitly to an empty string to keep the env var consistently a string.
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-} | |
| OIDC_CUSTOM_PARAMS: "${OIDC_CUSTOM_PARAMS:-""}" |
| OIDC_TENANT: ${OIDC_TENANT:-""} | ||
| OIDC_MAX_CLOCK_SKEW: ${OIDC_MAX_CLOCK_SKEW:-""} | ||
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-{}} | ||
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-} |
There was a problem hiding this comment.
Same issue as earlier in the file: this unquoted ${OIDC_CUSTOM_PARAMS:-} can become YAML null when unset and can be parsed as a YAML map when set to {...}, which can lead to Compose pass-through/omit semantics or unexpected stringification. Quote the interpolation or use an explicit empty-string default to ensure a string env var value.
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-} | |
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-""} |
| OIDC_TENANT: ${OIDC_TENANT:-""} | ||
| OIDC_MAX_CLOCK_SKEW: ${OIDC_MAX_CLOCK_SKEW:-""} | ||
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-{}} | ||
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-} |
There was a problem hiding this comment.
Same issue as earlier in the file: ${OIDC_CUSTOM_PARAMS:-} is unquoted, which can produce YAML null when unset and YAML map typing when set to {...}. Quote the interpolation or use an explicit empty-string default to ensure Compose passes a string env var value.
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-} | |
| OIDC_CUSTOM_PARAMS: "${OIDC_CUSTOM_PARAMS:-""}" |
| OIDC_TENANT: ${OIDC_TENANT:-""} | ||
| OIDC_MAX_CLOCK_SKEW: ${OIDC_MAX_CLOCK_SKEW:-""} | ||
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-{}} | ||
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-} |
There was a problem hiding this comment.
OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-} is unquoted in a YAML mapping. When the variable is unset this can become a YAML null value (which Compose treats as “take from host env” / omit), and when set to something like {...} it can be parsed as a YAML map rather than a string. To keep Compose behavior consistent and ensure the container always receives a string, quote the interpolation (e.g., wrap the value in double quotes) or use an explicit empty-string default.
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-} | |
| OIDC_CUSTOM_PARAMS: "${OIDC_CUSTOM_PARAMS:-}" |
| OIDC_TENANT: ${OIDC_TENANT:-""} | ||
| OIDC_MAX_CLOCK_SKEW: ${OIDC_MAX_CLOCK_SKEW:-""} | ||
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-{}} | ||
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-} |
There was a problem hiding this comment.
OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-} is unquoted in a YAML mapping. When the variable is unset this can become a YAML null value (Compose treats null as pass-through/omit), and when set to {...} it can be parsed as a YAML map instead of a string. Quote the interpolation (wrap in double quotes) or use an explicit empty-string default to ensure the env var value is always a string.
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-} | |
| OIDC_CUSTOM_PARAMS: "${OIDC_CUSTOM_PARAMS:-""}" |
| OIDC_TENANT: ${OIDC_TENANT:-""} | ||
| OIDC_MAX_CLOCK_SKEW: ${OIDC_MAX_CLOCK_SKEW:-""} | ||
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-{}} | ||
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-} |
There was a problem hiding this comment.
OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-} is unquoted. With the variable unset it can become YAML null (Compose treats as pass-through/omit), and with values like {...} it may be parsed as a YAML map instead of a string. Quote the interpolation or default explicitly to an empty string to keep the env var consistently typed as a string.
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-} | |
| OIDC_CUSTOM_PARAMS: "${OIDC_CUSTOM_PARAMS:-}" |
| OIDC_TENANT: ${OIDC_TENANT:-""} | ||
| OIDC_MAX_CLOCK_SKEW: ${OIDC_MAX_CLOCK_SKEW:-""} | ||
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-{}} | ||
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-} |
There was a problem hiding this comment.
OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-} is unquoted in the environment map. This can resolve to YAML null when unset (Compose pass-through/omit semantics) and can be parsed as a YAML map if the value starts with {...}. Quote the interpolation or use an explicit empty-string default to ensure the container receives a string.
| OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-} | |
| OIDC_CUSTOM_PARAMS: "${OIDC_CUSTOM_PARAMS:-""}" |
Change all 16 occurrences of OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-} to
OIDC_CUSTOM_PARAMS: ${OIDC_CUSTOM_PARAMS:-`} across 8 Docker Compose files.
An unquoted bare default resolves to YAML null when the variable is
unset. Using empty-string default is consistent with all other
OIDC_* string variables (OIDC_TENANT, OIDC_MAX_CLOCK_SKEW, etc.)
and addresses Copilot reviewer comments on PR open-metadata#26965.
Code Review ✅ Approved 1 resolved / 1 findingsUpdates OIDC_CUSTOM_PARAMS to use an empty default value to resolve Compose brace-parsing issues. The PR description has been updated to match the change. ✅ 1 resolved✅ Quality: PR description does not match actual change
OptionsDisplay: compact → Showing less information. Comment with these commands to change:
Was this helpful? React with 👍 / 👎 | Gitar |
Describe your changes:
Fixes #26775
Docker Compose rejects
${OIDC_CUSTOM_PARAMS:-{}}because the bare braces{}conflict with Compose's variable substitution syntax, causing a parse error on startup.Changed the default from
${OIDC_CUSTOM_PARAMS:-{}}to${OIDC_CUSTOM_PARAMS:-}(empty default) across all 8 Docker Compose files. This is correct because:conf/openmetadata.yamlalready usescustomParams: ${OIDC_CUSTOM_PARAMS:-}(empty default)getCustomParams() != nullbefore using the valueOIDC_CUSTOM_PARAMSFiles changed:
docker/development/docker-compose.ymldocker/development/docker-compose-postgres.ymldocker/development/docker-compose-gcp.ymldocker/development/docker-compose-postgres-fuseki.ymldocker/docker-compose-openmetadata/docker-compose-openmetadata.ymldocker/docker-compose-quickstart/docker-compose.ymldocker/docker-compose-quickstart/docker-compose-postgres.ymldocker/docker-compose-quickstart/docker-compose-rdf.ymlValidation: All compose files pass
docker compose config --quiet(GCP file fails due to a pre-existing unrelatedGOOGLE_APPLICATION_CREDENTIALSissue).Type of change:
Checklist:
Fixes <issue-number>: <short explanation>docker compose config --quieton all 8 files.Summary by Gitar
DataObservabilityGovernanceTab.spec.tsomjobdeploymentsThis will update automatically on new commits.