Browse Source

done

release/0.0.1
wyz 3 years ago
parent
commit
d55d52adba
3 changed files with 21 additions and 12 deletions
  1. +4
    -0
      Dockerfile
  2. +16
    -11
      pom.xml
  3. +1
    -1
      src/main/docker/Dockerfile

+ 4
- 0
Dockerfile View File

@ -0,0 +1,4 @@
FROM openjdk:8-jdk-alpine
VOLUME /tmp/docker-selfmade
ADD target/DeliveryTakingSystem-0.0.2-SNAPSHOT.jar app.jar
CMD java -jar app.jar

+ 16
- 11
pom.xml View File

@ -73,18 +73,23 @@
<!-- Docker maven plugin -->
<plugin>
<groupId>com.spotify</groupId>
<artifactId>docker-maven-plugin</artifactId>
<version>1.0.0</version>
<artifactId>dockerfile-maven-plugin</artifactId>
<version>1.4.6</version>
<executions>
<execution>
<id>default</id>
<goals>
<goal>build</goal>
<goal>push</goal>
</goals>
</execution>
</executions>
<configuration>
<imageName>${docker.image.prefix}/${project.artifactId}</imageName>
<dockerDirectory>src/main/docker</dockerDirectory>
<resources>
<resource>
<targetPath>/</targetPath>
<directory>${project.build.directory}</directory>
<include>${project.build.finalName}.jar</include>
</resource>
</resources>
<repository>betaberry/common</repository>
<tag>0.0.1</tag>
<buildArgs>
<JAR_FILE>app.jar</JAR_FILE>
</buildArgs>
</configuration>
</plugin>
<!-- Docker maven plugin -->

+ 1
- 1
src/main/docker/Dockerfile View File

@ -1,4 +1,4 @@
FROM openjdk:8-jdk-alpine
VOLUME /tmp
VOLUME /tmp/docker-selfmade
ADD DeliveryTakingSystem-0.0.2-SNAPSHOT.jar app.jar
ENTRYPOINT ["java","-Djava.security.egd=file:/dev/./urandom","-jar","/app.jar"]

Loading…
Cancel
Save