Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bootstrap alpine #1034

Open
nicholasdille opened this issue Oct 9, 2023 · 0 comments
Open

Bootstrap alpine #1034

nicholasdille opened this issue Oct 9, 2023 · 0 comments

Comments

@nicholasdille
Copy link
Contributor

#syntax=docker/dockerfile:1.6.0

FROM ghcr.io/uniget-org/tools/apk:main AS apk

FROM ubuntu:22.04 AS bootstrap
COPY --from=apk / /
WORKDIR /tmp/target
RUN <<EOF
/usr/local/bin/apk \
    --arch x86_64 \
    -X http://dl-cdn.alpinelinux.org/alpine/latest-stable/main/ \
    -U \
    --allow-untrusted \
    --root /tmp/target \
    --initdb \
    add alpine-base
EOF

FROM scratch
COPY --from=bootstrap /tmp/target /
RUN <<EOF
setup-apkrepos -f
EOF
CMD ["/bin/sh"]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant