Refactor testing into docker file
This means a decent scale refactor but ends with our testing being much simpler Key changes: * single Dockerfile for all services * tests moved into docker up so don't need to be run locally * configurations moved to environment
This commit is contained in:
parent
99da6c5d67
commit
14424c16ca
13 changed files with 171 additions and 107 deletions
16
Dockerfile
Normal file
16
Dockerfile
Normal file
|
@ -0,0 +1,16 @@
|
|||
FROM golang:latest
|
||||
LABEL maintainer="Marc Di Luzio <marc.diluzio@gmail.com>"
|
||||
|
||||
WORKDIR /app
|
||||
COPY . .
|
||||
RUN go mod download
|
||||
|
||||
# For /usr/share/dict/words
|
||||
RUN apt-get -q update && apt-get -qy install wamerican
|
||||
|
||||
# Build both executables
|
||||
RUN go build -o rove-server -ldflags="-X 'github.com/mdiluz/rove/pkg/version.Version=$(git describe --always --long --dirty --tags)'" cmd/rove-server/main.go
|
||||
RUN go build -o rove-accountant -ldflags="-X 'github.com/mdiluz/rove/pkg/version.Version=$(git describe --always --long --dirty --tags)'" cmd/rove-accountant/main.go
|
||||
|
||||
CMD [ "./rove-server" ]
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue