Files
helix/server/Dockerfile
T
siujamo 965b92b47d chore: restructure into monorepo and add open-source documentation
- Rename helix-server -> server and helix-web -> web
- Remove helix-api (bruno collection and docs site)
- Merge per-module .gitignore files into the root .gitignore
- Add README, AGENTS, CONTRIBUTING and MIT LICENCE
- Add full-stack docker-compose (postgres, redis, server, web via Caddy)
  with web Dockerfile, Caddyfile and Compose server config
- Keep the Gradle wrapper jar tracked after the .gitignore merge
- Copy gradle.properties into the server Docker build image
2026-09-01 10:48:45 +08:00

28 lines
661 B
Docker

FROM amazoncorretto:21 AS build
ARG ARTEFACT_VERSION='1.0.0'
WORKDIR /home/app
COPY gradlew .
COPY gradle gradle
COPY gradle.properties .
COPY build.gradle.kts .
COPY settings.gradle.kts .
COPY gradle/libs.versions.toml gradle/libs.versions.toml
RUN chmod +x gradlew && ./gradlew dependencies --no-daemon
COPY src src
RUN ./gradlew bootJar --no-daemon -PartefactVersion=${ARTEFACT_VERSION}
FROM amazoncorretto:21-alpine
WORKDIR /app
COPY --from=build /home/app/build/libs/helix-server-${ARTEFACT_VERSION}.jar app.jar
EXPOSE 8080
ENV JAVA_OPTS="-XX:+UseContainerSupport -XX:MaxRAMPercentage=75.0"
ENTRYPOINT ["sh", "-c", "java $JAVA_OPTS -jar app.jar"]