mirror of
https://github.com/SinTan1729/chhoto-url
synced 2024-12-26 07:38:36 -06:00
Added basic docker support
This commit is contained in:
parent
0e09d22025
commit
f4109b1b2c
2 changed files with 26 additions and 0 deletions
14
Dockerfile
Normal file
14
Dockerfile
Normal file
|
@ -0,0 +1,14 @@
|
||||||
|
FROM gradle:jdk11 AS build
|
||||||
|
COPY --chown=gradle:gradle . /home/gradle/src
|
||||||
|
WORKDIR /home/gradle/src
|
||||||
|
RUN gradle build --no-daemon
|
||||||
|
|
||||||
|
FROM openjdk:11-jre-slim
|
||||||
|
|
||||||
|
EXPOSE 4567
|
||||||
|
|
||||||
|
RUN mkdir /app
|
||||||
|
|
||||||
|
COPY --from=build /home/gradle/src/build/libs/*.jar /app/application.jar
|
||||||
|
|
||||||
|
ENTRYPOINT ["java", "-jar","/app/application.jar"]
|
12
docker-compose.yml
Normal file
12
docker-compose.yml
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
version: "3"
|
||||||
|
services:
|
||||||
|
url:
|
||||||
|
# TODO: Publish to docker hub
|
||||||
|
build:
|
||||||
|
context: .
|
||||||
|
ports:
|
||||||
|
- 4567:4567
|
||||||
|
environment:
|
||||||
|
- file.location=/urls.csv
|
||||||
|
volumes:
|
||||||
|
- ./urls.csv:/urls.csv
|
Loading…
Reference in a new issue