Skip to content

Commit

Permalink
rework docker
Browse files Browse the repository at this point in the history
  • Loading branch information
nr23730 committed Feb 18, 2022
1 parent a82305c commit a038f16
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 5 deletions.
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -37,4 +37,6 @@ settings.yaml
processed/*
!processed/.gitkeep
input/*
!input/.gitkeep
!input/.gitkeep
study/*
!study/.gitkeep
6 changes: 3 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@ FROM maven:3.8.4-openjdk-11-slim as build
COPY $PWD /mtbimporter
WORKDIR /mtbimporter

RUN mvn install
RUN mvn install -Dmaven.javadoc.skip=true -Dmaven.test.skip=true

FROM r-base:4.1.2

RUN apt-get update && apt-get install -y default-jre

RUN wget https://download.docker.com/linux/debian/dists/bullseye/pool/stable/amd64/docker-ce-cli_20.10.7~3-0~debian-bullseye_amd64.deb && dpkg -i docker-ce-cli_20.10.7~3-0~debian-bullseye_amd64.deb && rm docker-ce-cli_20.10.7~3-0~debian-bullseye_amd64.deb
RUN wget https://download.docker.com/linux/debian/dists/bullseye/pool/stable/amd64/docker-ce-cli_20.10.12~3-0~debian-bullseye_amd64.deb && dpkg -i docker-ce-cli_*.deb && rm docker-ce-cli_*.deb

COPY --from=build /mtbimporter/target/mtbimporter-*-jar-with-dependencies.jar /app/mtbimporter.jar
CMD ["java", "-jar", "/app/mtbimporter.jar"]
ENTRYPOINT ["java", "-jar", "/app/mtbimporter.jar"]
7 changes: 6 additions & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,15 @@ services:
restart: unless-stopped
build: ./
image: ghcr.io/buschlab/mtbimporter:latest
command: "/app/settings.yaml"
volumes:
- "/var/run/docker.sock:/var/run/docker.sock"
- "./settings.yaml:/app/settings.yaml"

- "./input:/app/input"
- "./mapper:/mapper"
- "./processed:/app/processed"
- "./study:/app/study"
- "./template:/app/template"
networks:
- mtbimporter_net

Expand Down

0 comments on commit a038f16

Please sign in to comment.