chore: validate rendered compose and surface Portainer errors in staging deploy - #206
Open
akandic47 wants to merge 1 commit into
Open
chore: validate rendered compose and surface Portainer errors in staging deploy#206akandic47 wants to merge 1 commit into
akandic47 wants to merge 1 commit into
Conversation
…ing deploy - validate docker-compose.rendered.yml with docker compose config before sending it to Portainer, failing early without printing the file - log the Portainer HTTP status code instead of failing with a bare curl exit 22 - drop stale SYG_RELAYER_COINMARKETCAPCONFIG_APIKEY from envsubst - always run cleanup so the rendered file is removed on failure
akandic47
requested review from
MakMuftic,
mpetrun5 and
mpetrunic
as code owners
August 21, 2026 14:16
mpetrun5
approved these changes
Aug 21, 2026
|
Go Test coverage is 36.5 %\ ✨ ✨ ✨ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Improves debuggability and safety of the staging Portainer deployment:
docker-compose.rendered.ymlwithdocker compose config -qbefore sending it to Portainer. A secret that corrupts the rendered YAML (e.g. a multi-line value) now fails fast in the render step, with validator output suppressed so no secret content can appear in public logs.--faildiscards the response), while still never printing the response body.SYG_RELAYER_COINMARKETCAPCONFIG_APIKEYfrom the envsubst list (secret removed in feat: replace coinmarketcap with pyth pricer #200).if: always()so the rendered file with secrets is removed even when the deploy fails.Related Issue Or Context
Staging deploys were failing with
Process completed with exit code 22and no further information.How Has This Been Tested? Testing details.
Render and validation logic exercised locally against
deploy/docker-compose.staging.yml: a valid render passes, a multi-line secret value fails validation before the Portainer call, and no file content is printed in either case.Types of changes