This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# 1. using golang image to build server side code (echo.labstack.com) | |
FROM golang:1.8 as goBuilder | |
RUN go get -u github.com/golang/dep/cmd/dep | |
WORKDIR /go/src/goApp | |
# optimization for caching layers | |
COPY ["Gopkg.toml", "Gopkg.lock", "./"] | |
RUN dep ensure --vendor-only | |
# coping source file and compile | |
COPY ["*.go", "./"] | |
RUN go install |