networkPolicy: make blockCloudMetadataEgress opt-out discoverable#347
Merged
Conversation
the metadata-egress block auto-enables whenever blob storage is keyless (no static credential). that's a heuristic: 'no static credential' covers both token-federated identities (IRSA / GKE Workload Identity / Azure Workload Identity), which never touch the metadata service and are safe to block, AND metadata-based identities (EC2 instance profile, GCE default service account, Azure IMDS managed identity), which fetch credentials from 169.254.169.254 and are silently broken by the block. rather than detect the auth form, surface the opt-out: - NOTES.txt: on install only (gated on .Release.IsInstall so it doesn't nag on every upgrade), when the block is active, point at networkPolicy.blockCloudMetadataEgress: false for the metadata-based cases. - values.yaml: correct the comment (the STS/IAM claim only holds for token-federated auth) and spell out when to set false. no behavior change to the auto-enable; discoverability only. bump chart 6.11.9 -> 6.11.10 (values comment + NOTES change).
JatinNanda
marked this pull request as ready for review
July 6, 2026 18:54
Contributor
|
| Filename | Overview |
|---|---|
| charts/retool/Chart.yaml | Bumps the chart patch version with no dependency or app version changes. |
| charts/retool/templates/NOTES.txt | Adds an install-only note for active metadata-egress blocking, with one wording issue for forced-on static-credential installs. |
| charts/retool/values.yaml | Updates the blockCloudMetadataEgress comment to distinguish token-federated and metadata-based identities. |
| values.yaml | Mirrors the chart values comment update. |
Reviews (1): Last reviewed commit: "networkPolicy: make blockCloudMetadataEg..." | Re-trigger Greptile
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
ryanartecona
approved these changes
Jul 6, 2026
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.
problem
networkPolicy.blockCloudMetadataEgress(added in 6.11.9) auto-enables whenever blob storage is keyless — detected as "no static credential set." That heuristic is an over-approximation:169.254.169.254→ safe to block ✅169.254.169.254→ the auto-block silently breaks blob storage ❌The two helpers even contradict each other:
retool.blobStorage.keylesslists "instance profile" as a keyless mode, whileretool.networkPolicy.blockMetadata.enabledasserts keyless "never [uses] the metadata service." The values comment only warned about data sources using the metadata endpoint, not blob-storage auth itself — so an instance-profile user gets no signal.approach
Per discussion, don't try to detect the auth form (fragile). Keep the auto-enable as-is and just make the opt-out impossible to miss:
.Release.IsInstall, so it doesn't nag on everyhelm upgrade) when the block is active: no-op for IRSA/WI, but if blob storage uses instance profile / default SA / IMDS managed identity, setblockCloudMetadataEgress: false.false. Applied to both synced copies.No behavior change to the auto-enable — discoverability only.
verification
NetworkPolicy still renders and denies
169.254.169.254/32for keyless.helm lintclean; both values.yaml copies in sync.Chart bumped
6.11.9 -> 6.11.10.follow-up (not in this PR)
The docs already carry the same opt-out guidance (tryretool/docs#2997). Longer term, the robust fix is to gate auto-enable on a positive federated-identity signal (IRSA annotation / WI label) rather than absence of a static key — but that's a behavior change for a separate discussion.