forked from moby/swarmkit
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
26 lines (20 loc) · 926 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
# NOTE(dperny): for some reason, alpine was giving me trouble
FROM golang:1.12.9-stretch
RUN apt-get update && apt-get install -y make git unzip
# should stay consistent with the version in .circleci/config.yml
ARG PROTOC_VERSION=3.6.1
# download and install protoc binary and .proto files
RUN curl --silent --show-error --location --output protoc.zip \
https://github.com/google/protobuf/releases/download/v$PROTOC_VERSION/protoc-$PROTOC_VERSION-linux-x86_64.zip \
&& unzip -d /usr/local protoc.zip include/\* bin/\* \
&& rm -f protoc.zip
WORKDIR /go/src/github.com/docker/swarmkit/
# install the dependencies from `make setup`
# we only copy `direct.mk` to avoid busting the cache too easily
COPY direct.mk .
RUN make --file=direct.mk setup
# now we can copy the rest
COPY . .
# default to just `make`. If you want to change the default command, change the
# default make command, not this command.
CMD ["make"]