Skip to content

armgit / floci

Public Imported from GitHub
0

Light, fluffy, and always free - The AWS Local Emulator alternative

fix: docker build on native

Juan Diego López525f106eb4d3
diff --git a/.dockerignore b/.dockerignore
index 0534c43946..1e3d8772f1 100644
--- a/.dockerignore
+++ b/.dockerignore
@@ -1,6 +1,8 @@
-target/
-data/
-.git/
-.idea/
-.DS_Store
-*.md
+*
+!docker/entrypoint.sh
+!target/*.so
+!target/*.properties
+!target/*-runner
+!target/*-runner.jar
+!target/lib/*
+!target/quarkus-app/*
diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml
index 65523bfd92..f03869a4f6 100644
--- a/.github/workflows/docker.yml
+++ b/.github/workflows/docker.yml
@@ -17,7 +17,7 @@ jobs:
- uses: actions/setup-java@v4
with:
- java-version: '25'
+ java-version: '24'
distribution: 'temurin'
cache: maven
diff --git a/Dockerfile.native-package b/Dockerfile.native-package
index 1ba080dd2c..3590ee36d6 100644
--- a/Dockerfile.native-package
+++ b/Dockerfile.native-package
@@ -1,16 +1,23 @@
-FROM quay.io/quarkus/quarkus-micro-image:2.0
+FROM registry.access.redhat.com/ubi9-minimal:9.7
+
+ARG VERSION=latest
+ARG BINARY_FILE=application
+
+ENV FLOCI_VERSION=${VERSION}
+
WORKDIR /app
VOLUME /app/data
-EXPOSE 4566
+RUN chown 1001 /app \
+ && chmod "g+rwX" /app \
+ && chown 1001:root /app
-ARG VERSION=latest
-ARG BINARY_FILE=application
+COPY --chown=1001:root target/*.properties target/*.so /app/
+COPY --chown=1001:root target/*-runner /app/application
-ENV FLOCI_VERSION=${VERSION}
+EXPOSE 4566
-COPY ${BINARY_FILE} /app/application
-RUN chmod +x /app/application
+USER 1001
-ENTRYPOINT ["/app/application"]
\ No newline at end of file
+CMD ["./application", "-Dquarkus.http.host=0.0.0.0"]
\ No newline at end of file