Skip to content

Commit

Permalink
build: add cni plugins
Browse files Browse the repository at this point in the history
Run with:

depot build  .
--build-arg BUILDKIT_VERSION=v0.11.6-depot.37
--build-arg MACHINE_AGENT_VERSION=v1.44.0
--build-arg CNI_VERSION=v1.4.0
--platform linux/amd64
-f Dockerfile.flyio

Signed-off-by: Chris Goller <[email protected]>
  • Loading branch information
goller committed Apr 24, 2024
1 parent 88ad7a1 commit 94459d6
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions Dockerfile.flyio
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ FROM --platform=$TARGETPLATFORM amazonlinux
ARG TARGETARCH
ARG BUILDKIT_VERSION
ARG MACHINE_AGENT_VERSION
ARG CNI_VERSION

RUN dnf upgrade -y && \
dnf install -y htop wget git lsof fuse3 tar pigz e2fsprogs psmisc && \
Expand All @@ -12,10 +13,15 @@ SHELL ["/bin/bash", "-o", "pipefail", "-c"]

RUN mkdir -p /etc/buildkit && \
curl -L "https://github.com/depot/buildkit/releases/download/${BUILDKIT_VERSION}/buildkit-${BUILDKIT_VERSION}.linux-${TARGETARCH}.tar.gz" | \
tar -xz -C /usr/bin --strip-components=1
tar -zxv -C /usr/bin --strip-components=1

RUN curl -L "https://dl.depot.dev/machine-agent/download/linux/$(uname -m)/${MACHINE_AGENT_VERSION}" | \
tar -zx --strip-components=1 --directory /usr/bin bin/machine-agent
tar -zxv --strip-components=1 --directory /usr/bin bin/machine-agent

RUN mkdir -p /opt/cni/bin/ && \
curl -L "https://github.com/containernetworking/plugins/releases/download/${CNI_VERSION}/cni-plugins-linux-${TARGETARCH}-${CNI_VERSION}.tgz" | \
tar -C /opt/cni/bin/ -zxv


# TODO: install vector
# TODO: binfmt/dagger engine
Expand Down

0 comments on commit 94459d6

Please sign in to comment.