From a07e1b3931e4813517e9874c6d41b1e60410aa55 Mon Sep 17 00:00:00 2001 From: Daniel von Atzigen Date: Wed, 27 Nov 2024 09:58:45 +0100 Subject: [PATCH] Add APP_VERSION to prod Dockerfiles --- api/Dockerfile | 6 ++++++ ui/Dockerfile | 3 +++ 2 files changed, 9 insertions(+) diff --git a/api/Dockerfile b/api/Dockerfile index 7fe160f24..a1541cc73 100644 --- a/api/Dockerfile +++ b/api/Dockerfile @@ -1,5 +1,8 @@ FROM rust:1.82 AS build +ARG APP_VERSION +ENV APP_VERSION=${APP_VERSION} + RUN apt update && apt install -y musl-tools musl-dev RUN rustup target add x86_64-unknown-linux-musl @@ -13,6 +16,9 @@ RUN cargo build --target x86_64-unknown-linux-musl --release --quiet FROM alpine:3.17 +ARG APP_VERSION +ENV APP_VERSION=${APP_VERSION} + RUN apk add --no-cache util-linux ## Import from builder. diff --git a/ui/Dockerfile b/ui/Dockerfile index a62fd2fa9..308323667 100644 --- a/ui/Dockerfile +++ b/ui/Dockerfile @@ -1,5 +1,8 @@ FROM node:22.5.1-alpine AS build +ARG APP_VERSION +ENV APP_VERSION=${APP_VERSION} + WORKDIR /app COPY . .