Backend/Dockerfile

23 lines
486 B
Docker

ARG JAVA_VERSION=11
FROM openjdk:$JAVA_VERSION
WORKDIR /usr/bin/cre/
ARG CRE_ARTIFACT_NAME=ColorRecipesExplorer
COPY $CRE_ARTIFACT_NAME.jar ColorRecipesExplorer.jar
ARG CRE_PORT=9090
EXPOSE $CRE_PORT
ENV spring_profiles_active=h2,rest
ENV server_port=$PORT
ENV spring_datasource_url=jdbc:h2:mem:cre
ENV spring_datasource_username=root
ENV spring_datasource_password=pass
VOLUME /usr/bin/cre/data
VOLUME /usr/bin/cre/config
ENTRYPOINT ["java", "-jar", "ColorRecipesExplorer.jar"]