Skip to content

Skip piped-config volume when launcher loads config from git - #7141

Open
kishoredurai wants to merge 1 commit into
pipe-cd:masterfrom
kishoredurai:fix/piped-chart-launcher-configmap-mount
Open

Skip piped-config volume when launcher loads config from git#7141
kishoredurai wants to merge 1 commit into
pipe-cd:masterfrom
kishoredurai:fix/piped-chart-launcher-configmap-mount

Conversation

@kishoredurai

Copy link
Copy Markdown

What this PR does:

Only render the piped-config ConfigMap volume and volumeMount in the piped Deployment when a local ConfigMap is actually consumed. Specifically, skip them when launcher.enabled and launcher.configFromGitRepo.enabled are both true — in that mode the launcher fetches piped config from git (via --config-from-git-repo=true and the --git-* flags) and does not read /etc/piped-config/.

Why we need it:

With launcher.enabled: true + launcher.configFromGitRepo.enabled: true, the local ConfigMap is unused. Users naturally set config.create: false in that mode, but that produces an invalid Deployment (empty configMap.name) and helm upgrade fails:

Deployment.apps "piped" is invalid:
  spec.template.spec.volumes[1].configMap.name: Required value
  spec.template.spec.containers[0].volumeMounts[1].name: Not found: "piped-config"

Which issue(s) this PR fixes:

Fixes #7140

Does this PR introduce a user-facing change?:

  • How are users affected by this change: Users running the launcher with configFromGitRepo can now set config.create: false and install the chart cleanly. All other modes (piped without launcher, and launcher with a local ConfigMap) render identically to before.
  • Is this breaking change: No.
  • How to migrate (if breaking change): N/A.

Verificationhelm template in three modes:

  • Default (no launcher): piped-config volume + mount present. ✓
  • launcher.enabled=true, configFromGitRepo.enabled=false: piped-config still present (launcher reads from mounted ConfigMap). ✓
  • launcher.enabled=true + configFromGitRepo.enabled=true + config.create=false: piped-config absent, launcher uses --git-* flags. ✓

helm lint manifests/piped passes.

When `launcher.enabled` and `launcher.configFromGitRepo.enabled` are both true, the launcher fetches piped config from a git repository and does not read `/etc/piped-config/`. The chart, however, unconditionally rendered the `piped-config` volume and volumeMount, so setting `config.create: false` produced an invalid Deployment (empty ConfigMap name).

Guard the volume and volumeMount so they are only rendered when a local ConfigMap is actually consumed.

Signed-off-by: kishoredurai <kishoredurai7@gmail.com>
@kishoredurai
kishoredurai requested a review from a team as a code owner August 6, 2026 12:28
@github-actions

github-actions Bot commented Aug 6, 2026

Copy link
Copy Markdown
Contributor

👋 Hi @kishoredurai, welcome to PipeCD and thanks for opening your first pull request!

We’re really happy to have you here

Before your PR gets merged, please check a few important things below.


Helpful resources


DCO Sign-off

All commits must include a Signed-off-by line to comply with the Developer Certificate of Origin (DCO).

In case you forget to sign-off your commit(s), follow these steps:

For the last commit:

git commit --amend --signoff
git push --force-with-lease

For multiple commits:

git rebase --signoff origin/master
git push --force-with-lease

Run checks locally

Before pushing updates, please run:

make check

This runs the same checks as CI and helps catch issues early.


💬 Need help?

If anything is unclear, feel free to ask in this PR or join us on the CNCF Slack in the #pipecd channel.
You can get your Slack invite from: https://communityinviter.com/apps/cloud-native/cncf

Thanks for contributing to PipeCD! ❤️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

piped chart: piped-config ConfigMap mounted unconditionally, breaks launcher configFromGitRepo

1 participant