Dockerfile 1.03 KB
Newer Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
# Copyright 2017 The Kubernetes Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

15
# builder image
16
FROM golang:1.12.5 as builder
17

njuettner's avatar
njuettner committed
18
WORKDIR /github.com/kubernetes-incubator/external-dns
19
COPY . .
njuettner's avatar
njuettner committed
20
RUN go mod vendor
21
22
RUN make test
RUN make build
23

24
# final image
25
FROM alpine:3.9
26
LABEL maintainer="Team Teapot @ Zalando SE <team-teapot@zalando.de>"
27

28
RUN apk add ca-certificates && update-ca-certificates
29
COPY --from=builder /github.com/kubernetes-incubator/external-dns/build/external-dns /bin/external-dns
30

31
USER nobody
32

33
ENTRYPOINT ["/bin/external-dns"]