Skip to content

Commit

Permalink
feat(wolfi-dx-toolbox): Install latest utilities, match melange SDK a…
Browse files Browse the repository at this point in the history
…dditions

After switching from the Wolfi SDK to the base image, we lost the latest versions
of a few utilities in the process. This corrects that

This ships the latest versions of melange, apko, goimports, wolfictl, and yam

Signed-off-by: RJ Trujillo <eyecantcu@pm.me>
  • Loading branch information
EyeCantCU committed Feb 11, 2024
1 parent f1502e2 commit 26cf3b4
Showing 1 changed file with 26 additions and 0 deletions.
26 changes: 26 additions & 0 deletions toolboxes/wolfi-toolbox/Containerfile.wolfi
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,32 @@ RUN grep -v '^#' /tmp/packages.wolfi | xargs apk add && \
grep -v '^#' /tmp/packages.wolfi-dx | xargs apk add \
; fi

# DX: Include utilities available in the melange SDK
RUN if [[ "${IMAGE_NAME}" =~ "dx" ]]; then \
cd /tmp && \
export PATH="/tmp/go/bin:${PATH}" && \
# go setup
export GOPATH="/tmp/go" && \
mkdir -p "${GOPATH}" && \
# goimports
go install golang.org/x/tools/cmd/goimports@latest && \
mkdir -p "/usr/bin" && \
mv "${GOPATH}/bin/goimports" "/usr/bin" && \
# melange
git clone https://github.com/chainguard-dev/melange.git && \
(cd melange && make melange install) && \
# apko
git clone https://github.com/chainguard-dev/apko.git && \
(cd apko && make apko install) && \
# wolfictl
git clone https://github.com/wolfi-dev/wolfictl.git && \
(cd wolfictl && make wolfictl install) && \
# yam
git clone https://github.com/chainguard-dev/yam.git && \
cd yam && \
go build -v -o "/usr/bin/yam" . \
; fi

# Get Distrobox-host-exec and host-spawn
RUN git clone https://github.com/89luca89/distrobox.git --single-branch /tmp/distrobox && \
cp /tmp/distrobox/distrobox-host-exec /usr/bin/distrobox-host-exec && \
Expand Down

0 comments on commit 26cf3b4

Please sign in to comment.