Skip to content

Commit

Permalink
cni-metrics-helper minimal base image; simplify dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
jdn5126 committed Dec 28, 2022
1 parent a5823c0 commit 6fac830
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 11 deletions.
2 changes: 0 additions & 2 deletions scripts/dockerfiles/Dockerfile.init
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,6 @@ ENV GOPROXY=direct

# Copy modules in before the rest of the source to only expire cache on module changes:
COPY go.mod go.sum ./
RUN go mod download

COPY Makefile ./
RUN make plugins && make debug-script

Expand Down
10 changes: 3 additions & 7 deletions scripts/dockerfiles/Dockerfile.metrics
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,13 @@ WORKDIR /go/src/github.com/aws/amazon-vpc-cni-k8s
ENV GO111MODULE=on
ENV GOPROXY=direct

# Copy modules in before the rest of the source to only expire cache on module
# changes:
# Copy modules in before the rest of the source to only expire cache on module changes:
COPY go.mod go.sum ./
RUN go mod download

COPY . ./
RUN make build-metrics

FROM public.ecr.aws/amazonlinux/amazonlinux:2
RUN yum update -y && \
yum clean all
# Build from EKS minimal base + glibc
FROM public.ecr.aws/eks-distro-build-tooling/eks-distro-minimal-base-glibc:latest.2

# Copy our bundled certs to the first place go will check: see
# https://golang.org/src/pkg/crypto/x509/root_unix.go
Expand Down
2 changes: 0 additions & 2 deletions scripts/dockerfiles/Dockerfile.release
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,6 @@ ENV GOPROXY=direct

# Copy modules in before the rest of the source to only expire cache on module changes:
COPY go.mod go.sum ./
RUN go mod download

COPY Makefile ./
COPY . ./
RUN make build-aws-vpc-cni && make build-linux
Expand Down

0 comments on commit 6fac830

Please sign in to comment.