Skip to content

Commit

Permalink
Merge pull request #3 from ironcladlou/dockerfile-rhel
Browse files Browse the repository at this point in the history
Add a RHEL7 Dockerfile and standardize format
  • Loading branch information
openshift-merge-robot committed Nov 13, 2018
2 parents 964d7e3 + 089521f commit 4fbb9ba
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 4 deletions.
13 changes: 13 additions & 0 deletions Dockerfile.openshift
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
FROM registry.svc.ci.openshift.org/openshift/release:golang-1.10 AS builder
WORKDIR /go/src/github.com/coredns/coredns
COPY . .
RUN go build -o coredns .

FROM registry.svc.ci.openshift.org/openshift/origin-v4.0:base
COPY --from=builder /go/src/github.com/coredns/coredns/coredns /usr/bin/

ENTRYPOINT ["/usr/bin/coredns"]

LABEL io.k8s.display-name="CoreDNS" \
io.k8s.description="CoreDNS delivers the DNS and Discovery Service for a Kubernetes cluster." \
maintainer="dev@lists.openshift.redhat.com"
7 changes: 3 additions & 4 deletions images/coredns/Dockerfile → Dockerfile.openshift.rhel7
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
FROM openshift/origin-release:golang-1.10 as build
FROM registry.svc.ci.openshift.org/ocp/builder:golang-1.10 AS builder
WORKDIR /go/src/github.com/coredns/coredns
ENV GOPATH=/go
COPY . .
RUN go build -o coredns .

FROM centos:7
COPY --from=build /go/src/github.com/coredns/coredns/coredns /usr/bin/coredns
FROM registry.svc.ci.openshift.org/ocp/4.0:base
COPY --from=builder /go/src/github.com/coredns/coredns/coredns /usr/bin/

ENTRYPOINT ["/usr/bin/coredns"]

Expand Down

0 comments on commit 4fbb9ba

Please sign in to comment.