summaryrefslogtreecommitdiff
path: root/Dockerfile
diff options
context:
space:
mode:
Diffstat (limited to 'Dockerfile')
-rw-r--r--Dockerfile19
1 files changed, 19 insertions, 0 deletions
diff --git a/Dockerfile b/Dockerfile
new file mode 100644
index 0000000..b65f8e2
--- /dev/null
+++ b/Dockerfile
@@ -0,0 +1,19 @@
+# Build + test stage: a failing test fails the image build, which is what lizCI checks.
+FROM eclipse-temurin:21-jdk AS build
+WORKDIR /src
+# Warm the Gradle wrapper and dependency cache before copying sources.
+COPY gradlew settings.gradle.kts build.gradle.kts gradle.properties ./
+COPY gradle gradle
+COPY core/build.gradle.kts core/
+COPY ui/build.gradle.kts ui/
+COPY desktop/build.gradle.kts desktop/
+RUN ./gradlew --no-daemon -q help
+COPY . .
+RUN ./gradlew --no-daemon check :desktop:createDistributable
+
+# Artifact image: just the packaged Linux desktop app (with its bundled runtime).
+FROM alpine:3.20 AS rookery
+ARG COMMIT=unknown
+COPY --from=build /src/desktop/build/compose/binaries/main/app/rookery /opt/rookery
+RUN printf '%s' "$COMMIT" > /opt/rookery/commit
+CMD ["ls", "/opt/rookery"]