Add Dockerfile
This commit is contained in:
23
Dockerfile
Normal file
23
Dockerfile
Normal file
@@ -0,0 +1,23 @@
|
||||
FROM golang:1.14.0-alpine3.11
|
||||
|
||||
# Add Maintainer Info
|
||||
LABEL maintainer="structix <kontakt@structix.de>"
|
||||
|
||||
RUN mkdir /trikotwaschliste && apk add git bash
|
||||
WORKDIR /trikotwaschliste
|
||||
COPY . .
|
||||
|
||||
# Install all the dependencies and build
|
||||
# Use the online repositories to build the goapi:
|
||||
RUN go get -d -v ./... && go install -v ./... && go build -tags=jsoniter -o trikotwaschliste
|
||||
#
|
||||
# Use the vendor folder:
|
||||
#RUN go build -mod vendor -tags=jsoniter -o trikotwaschliste
|
||||
|
||||
ENV GIN_MODE=release
|
||||
ENV LOG=*
|
||||
EXPOSE 8082
|
||||
|
||||
|
||||
# Run the executable
|
||||
CMD ["./trikotwaschliste"]
|
Reference in New Issue
Block a user