1
1
mirror of https://github.com/cooperspencer/gickup synced 2024-11-08 12:09:18 +01:00

Added Dockerfile & docker-compose

This commit is contained in:
Phil 2021-12-09 12:19:56 +01:00
parent 364c04bd98
commit 3df7b14f31
No known key found for this signature in database
GPG Key ID: 91884FA482AA7CB3
2 changed files with 20 additions and 0 deletions

12
Dockerfile Normal file

@ -0,0 +1,12 @@
FROM golang:alpine as builder
WORKDIR /go/src/github.com/cooperspencer/gickup
COPY . .
RUN go get -d -v ./...
RUN CGO_ENABLED=0 go build -a -installsuffix cgo -o app .
FROM scratch as production
WORKDIR /
COPY --from=builder /go/src/github.com/cooperspencer/gickup/app /gickup/app
CMD ["./gickup/app"]

8
docker-compose.yml Normal file

@ -0,0 +1,8 @@
version: "3"
services:
runner:
build: .
# image: cooperspencer/gickup:latest # TODO: Enable the Build in Docker Hub
volumes:
- ${PWD}/config.yml:/gickup/config.yml
command: ["./gickup/app", "/gickup/config.yml"]