Conversation
Signed-off-by: Kevin Su <pingsutw@apache.org>
Contributor
There was a problem hiding this comment.
Pull request overview
Adds a rootless variant of the devbox container image to support running k3s without privileged capabilities (e.g., in restricted Kubernetes/Knative environments).
Changes:
- Add a
build-rootlessMakefile target to build a new rootless devbox image. - Introduce
Dockerfile.rootlessthat builds a Debian-based image intended to run k3s in rootless mode, with preloaded images/manifests and embedded Postgres support.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 5 comments.
| File | Description |
|---|---|
| docker/devbox-bundled/Makefile | Adds a build-rootless target to build/tag the rootless image. |
| docker/devbox-bundled/Dockerfile.rootless | New Debian-based Dockerfile for a rootless k3s devbox variant. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
+144
to
+146
| ENV HOME=/home/flyte | ||
| ENV XDG_RUNTIME_DIR=/home/flyte/.run | ||
|
|
| # Install k3s binary | ||
| RUN set -ex; \ | ||
| K3S_ARCH=$([ "$TARGETARCH" = "arm64" ] && echo "-arm64" || echo ""); \ | ||
| curl -fL "https://github.com/k3s-io/k3s/releases/download/${K3S_VERSION}/k3s${K3S_ARCH}" -o /usr/local/bin/k3s; \ |
Comment on lines
+147
to
+150
| VOLUME /var/lib/flyte/storage | ||
|
|
||
| USER flyte | ||
| WORKDIR /home/flyte |
Comment on lines
+124
to
+128
| # Stage k3s air-gapped images and manifests under the flyte user's home so | ||
| # rootless k3s (which uses ~/.rancher/k3s/...) can pick them up. | ||
| COPY --from=builder /build/images/ /home/flyte/.rancher/k3s/agent/images/ | ||
| COPY images/tar/${TARGETARCH}/ /home/flyte/.rancher/k3s/agent/images/ | ||
| COPY manifests/ /home/flyte/.rancher/k3s/server/manifests-staging/ |
| USER flyte | ||
| WORKDIR /home/flyte | ||
|
|
||
| ENTRYPOINT [ "/usr/local/bin/k3d-entrypoint-rootless.sh" ] |
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.
Tracking issue
Why are the changes needed?
What changes were proposed in this pull request?
How was this patch tested?
Labels
Please add one or more of the following labels to categorize your PR:
This is important to improve the readability of release notes.
Setup process
Screenshots
Check all the applicable boxes
Related PRs
Stack
If you do use
git townto manage PR Stacks, the stack relevant to this PRwill show below. Otherwise, you can ignore this section.
Docs link