source: code/trunk/Dockerfile@ 90

Last change on this file since 90 was 90, checked in by alex, 6 years ago

Add Dockerfile and Makefile

File size: 442 bytes
RevLine 
[90]1# STEP 1 build executable binary
2FROM golang:alpine as builder
3
4WORKDIR $GOPATH/src/github.com/asciimoo/morty
5
6RUN apk add --no-cache git
7
8COPY . .
9RUN go get -d -v
10RUN go build .
11
12# STEP 2 build the image including only the binary
13FROM alpine:latest
14
15EXPOSE 3000
16
17WORKDIR /
18RUN apk --no-cache add ca-certificates
19RUN mkdir /etc/morty
20
21COPY --from=builder /go/src/github.com/asciimoo/morty/morty /usr/bin/morty
22
23ENTRYPOINT ["/usr/bin/morty"]
Note: See TracBrowser for help on using the repository browser.