Skip to content
Snippets Groups Projects
Select Git revision
  • 8b31832482010483b15ad64dd89caf753ec972bd
  • master default protected
  • dev protected
  • replication_test
  • release-1.10 protected
  • release-1.9 protected
  • 551-init-broker-service-permissions
  • 549-test-oai-pmh
  • 545-saving-multiple-times-breaks-pid-metadata
  • 499-standalone-compute-service-2
  • 539-load-tests
  • hotfix/helm-chart
  • luca_ba_new_interface
  • 534-bug-when-adding-access-to-user-that-is-not-registered-at-dashboard-service
  • release-1.8 protected
  • 533-integrate-semantic-recommendation
  • feature/openshift
  • 518-spark-doesn-t-map-the-headers-correct
  • 485-fixity-checks
  • 530-various-schema-problems-with-subsets
  • release-1.7 protected
  • v1.10.2 protected
  • v1.10.1 protected
  • v1.10.0-rc13 protected
  • v1.10.0-rc12 protected
  • v1.10.0-rc11 protected
  • v1.10.0-rc10 protected
  • v1.10.0-rc9 protected
  • v1.10.0-rc8 protected
  • v1.10.0-rc7 protected
  • v1.10.0-rc6 protected
  • v1.10.0-rc5 protected
  • v1.10.0-rc4 protected
  • v1.10.0-rc3 protected
  • v1.10.0-rc2 protected
  • v1.10.0rc1 protected
  • v1.10.0rc0 protected
  • v1.10.0 protected
  • v1.9.3 protected
  • v1.9.2 protected
  • v1.9.2-rc0 protected
41 results

Dockerfile

Blame
  • Martin Weise's avatar
    e171b057
    History
    Dockerfile 1.38 KiB
    ###### FIRST STAGE ######
    FROM fda-metadata-db:latest as dependency
    MAINTAINER Martin Weise <martin.weise@tuwien.ac.at>
    
    ###### SECOND STAGE ######
    FROM maven:slim as build
    
    COPY ./pom.xml ./
    
    RUN mvn -fn -B dependency:go-offline > /dev/null
    
    COPY --from=dependency /root/.m2/repository/at/tuwien /root/.m2/repository/at/tuwien
    
    COPY ./rest-service ./rest-service
    COPY ./services ./services
    COPY ./report ./report
    
    # Make sure it compiles
    RUN mvn -q clean package -DskipTests
    
    ###### THIRD STAGE ######
    FROM openjdk:11-jre-slim as runtime
    
    ENV METADATA_DB=fda
    ENV METADATA_USERNAME=root
    ENV METADATA_PASSWORD=dbrepo
    ENV BROKER_USERNAME=fda
    ENV BROKER_PASSWORD=fda
    ENV WEBSITE=http://example.com
    ENV GATEWAY_ENDPOINT=http://gateway-service:9095
    ENV TOKEN_MAX=5
    ENV MAIL_FROM="Database Repository <noreply@example.com>"
    ENV MAIL_REPLY_TO="Somebody <somebody@example.com>"
    ENV MAIL_VERIFY=false
    ENV JWT_ISSUER=dbrepo
    ENV JWT_SECRET=secret
    ENV JWT_EXPIRATION=86400000
    ENV SMTP_HOST=""
    ENV SMTP_PORT=""
    ENV SMTP_USERNAME=""
    ENV SMTP_PASSWORD=""
    ENV LOG_LEVEL=debug
    
    VOLUME /tmp
    
    COPY ./service_ready /usr/bin
    RUN chmod +x /usr/bin/service_ready
    
    HEALTHCHECK --interval=10s --timeout=5s --retries=12 CMD service_ready
    
    COPY --from=build ./rest-service/target/rest-service-*.jar ./authentication-service.jar
    
    EXPOSE 9097
    
    ENTRYPOINT ["java", "-Dlog4j2.formatMsgNoLookups=true", "-jar", "./authentication-service.jar"]