{{ message }}
(feat) Rootless dind mode#4541
Open
alexrecuenco wants to merge 1 commit into
Open
Conversation
Currently we cant overwrite the dind deployment to use rootless mode, this updates the dind deployment to use rootless mode instead of privileged mode
Author
Contributor
There was a problem hiding this comment.
Pull request overview
This PR adds a containerMode.rootless option to the gha-runner-scale-set Helm chart so that, when using containerMode.type=dind, the chart can render a Docker-in-Docker sidecar using a rootless image and without privileged mode.
Changes:
- Document a new
containerMode.rootlessvalues option for dind mode. - Render the dind container image as
docker:dind-rootlesswhen rootless is enabled. - Switch the dind container securityContext from
privileged: trueto a non-privileged configuration for rootless mode (including Unconfined seccomp/AppArmor settings).
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| charts/gha-runner-scale-set/values.yaml | Documents the new containerMode.rootless option and its intended security posture. |
| charts/gha-runner-scale-set/templates/_helpers.tpl | Implements conditional rendering for rootless dind image + securityContext. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
+123
to
+131
| {{- if $rootless }} | ||
| privileged: false | ||
| appArmorProfile: | ||
| type: Unconfined | ||
| seccompProfile: | ||
| type: Unconfined | ||
| {{- else }} | ||
| privileged: true | ||
| {{- end }} |
Comment on lines
+113
to
+114
| {{- $rootless := and .Values.containerMode (.Values.containerMode.rootless) }} | ||
| image: {{ if $rootless }}docker:dind-rootless{{ else }}docker:dind{{ end }} |
Comment on lines
+121
to
+124
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.

Currently we can't overwrite the dind deployment to use rootless mode, this updates the dind deployment to use rootless mode instead of privileged mode when required