Skip to content
Snippets Groups Projects
Dockerfile.gradle.develop 977 B
Newer Older
  • Learn to ignore specific revisions
  • FROM griefed/baseimage-ubuntu-jdk-8:2.0.7 AS builder
    
    Griefed's avatar
    Griefed committed
    ARG BRANCH_OR_TAG=main
    
    
    RUN \
      apt-get update && apt-get upgrade -y && \
      apt-get install -y \
        libatomic1 && \
      git clone \
    
    Griefed's avatar
    Griefed committed
        -b $BRANCH_OR_TAG \
    
          REPOSITORY.git \
            /tmp/REPOSITORY && \
      chmod +x /tmp/REPOSITORY/gradlew* && \
      cd /tmp/REPOSITORY && \
      ./gradlew about installQuasar cleanFrontend assembleFrontend copyDist build --info -x test && \
      ls -ahl ./build/libs/
    
    
    FROM griefed/baseimage-ubuntu-jdk-8:2.0.7
    
    
    LABEL maintainer="Griefed <griefed@griefed.de>"
    LABEL description="DESCRIPTION"
    
    RUN \
      echo "**** Bring system up to date ****" && \
      apt-get update && apt-get upgrade -y && \
      echo "**** Creating our folder(s) ****" && \
      mkdir -p \
        /app/REPOSITORY/data && \
      echo "**** Cleanup ****" && \
        rm -rf \
          /root/.cache \
          /tmp/*
    
    COPY --from=builder tmp/REPOSITORY/build/libs/REPOSITORY.jar /app/REPOSITORY/REPOSITORY.jar
    
    COPY root/ /
    
    VOLUME /config
    
    EXPOSE 8080