# Use the official AdoptOpenJDK for a base image. # https://hub.docker.com/_/openjdk FROM openjdk:8-slim WORKDIR /app ARG PROVIDER_NAME ENV PROVIDER_NAME $PROVIDER_NAME ARG PORT ENV PORT $PORT # Copy the jar to the production image from the builder stage. COPY provider/indexer-${PROVIDER_NAME}/target/indexer-${PROVIDER_NAME}-*-spring-boot.jar indexer-${PROVIDER_NAME}.jar # Run the web service on container startup. CMD java -Djava.security.egd=indexer:/dev/./urandom -Dserver.port=${PORT} -Dlog4j.formatMsgNoLookups=true -jar /app/indexer-${PROVIDER_NAME}.jar