Skip to content

Commit

Permalink
feat(bluefin-cli): Add host-spawn and create symlinks
Browse files Browse the repository at this point in the history
Adds Distrobox-host-exec and host-spawn in the build process.

Creates symlinks for running host level things on the host.

Co-Authored-By: Kyle Gospodnetich <[email protected]>
  • Loading branch information
m2Giles and KyleGospo committed Jan 2, 2024
1 parent e4ab9d3 commit fdc6032
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions toolboxes/Containerfile.bluefin-cli
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,20 @@ RUN grep -v '^#' /toolbox-packages | xargs apk add

RUN rm /toolbox-packages

# 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 && \
wget https://github.com/1player/host-spawn/releases/download/$(cat /tmp/distrobox/distrobox-host-exec | grep host_spawn_version= | cut -d "\"" -f 2)/host-spawn-$(uname -m) -O /usr/bin/host-spawn && \
chmod +x /usr/bin/host-spawn && \
rm -drf /tmp/distrobox

# Make some symlinks
RUN mkdir -p /usr/local/bin && \
ln -fs /usr/bin/distrobox-host-exec /usr/local/bin/docker && \
ln -fs /usr/bin/distrobox-host-exec /usr/local/bin/flatpak && \
ln -fs /usr/bin/distrobox-host-exec /usr/local/bin/podman && \
ln -fs /usr/bin/distrobox-host-exec /usr/local/bin/rpm-ostree

# Make Sudo Work (Assumes UID = 1000)
COPY ./toolboxes/files.bluefin-cli/etc/sudoers /etc/sudoers
COPY ./toolboxes/files.bluefin-cli/etc/pam.d /etc/pam.d
Expand Down

0 comments on commit fdc6032

Please sign in to comment.