don't use relative path
FROM maven:3.6.3-jdk-13 as build_jar
RUN yum install git -y
-WORKDIR /jar
-COPY pom.xml .
+RUN mkdir /jar
+COPY pom.xml /jar/pom.xml
RUN mvn dependency:go-offline
-COPY src/ .
+COPY src/ /jar/src/
# @todo #40 Propagate git tag
# I.e. if docker image is based on version 1.5.0, the version should be propagated to the app jar
# file.
@@ -12,7 +12,7 @@ RUN mvn package -B --quiet
FROM adoptopenjdk/openjdk13:alpine-jre
LABEL description="Artipie is a binary repository managment tool."
LABEL maintainer="titantins@gmail.com"
-WORKDIR /artipie
+RUN mkdir /artipie
COPY --from=build_jar /jar/target/artipie-jar-with-dependencies.jar /artipie/artipie.jar
VOLUME /artipie/repositories
RUN echo -e "meta:\n\
