From 87bad19bd1930422a33257ff588ab15283e06f96 Mon Sep 17 00:00:00 2001 From: gigirassy Date: Wed, 17 Jun 2026 07:29:34 +0200 Subject: [PATCH] Add Dockerfile --- Dockerfile | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 Dockerfile diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..45856a4 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,32 @@ +ARG RIPTIDE_TAG=0.1.0 + +FROM rust:alpine AS build + +ARG TARGETARCH +ARG RIPTIDE_TAG + +ENV RUSTFLAGS="-C target-feature=+crt-static" + +RUN apk add --no-cache build-base musl-dev pkgconf git + +RUN case "$TARGETARCH" in \ + amd64) cargo_target=x86_64-unknown-linux-musl ;; \ + arm64) cargo_target=aarch64-unknown-linux-musl ;; \ + *) exit 1 ;; \ + esac && \ + rustup target add "$cargo_target" && \ + cargo install \ + --git https://codeberg.org/gigirassy/riptide \ + --tag "$RIPTIDE_TAG" \ + --root /out \ + --target "$cargo_target" + +FROM kgrv/mini:tn + +COPY --from=build --chown=mini:mini /out/bin/riptide /riptide + +VOLUME ["/data"] + +WORKDIR /data + +CMD ["tini", "--", "/riptide"] \ No newline at end of file