2018-12-05 02:08:09 +00:00
|
|
|
# This Dockerfile is used to build the image available on DockerHub
|
2019-07-04 08:07:37 +00:00
|
|
|
FROM centos:centos7 as build
|
2018-07-27 10:51:51 +00:00
|
|
|
|
|
|
|
# Add everything
|
|
|
|
ADD . /usr/src/multus-cni
|
|
|
|
|
2020-04-17 19:19:35 +00:00
|
|
|
ENV INSTALL_PKGS "git golang-1.13.10-0.el7.x86_64"
|
2018-12-04 09:20:22 +00:00
|
|
|
RUN rpm --import https://mirror.go-repo.io/centos/RPM-GPG-KEY-GO-REPO && \
|
|
|
|
curl -s https://mirror.go-repo.io/centos/go-repo.repo | tee /etc/yum.repos.d/go-repo.repo && \
|
|
|
|
yum install -y $INSTALL_PKGS && \
|
2018-07-27 10:51:51 +00:00
|
|
|
rpm -V $INSTALL_PKGS && \
|
|
|
|
cd /usr/src/multus-cni && \
|
2020-05-28 20:43:59 +00:00
|
|
|
./hack/build-go.sh
|
2018-07-27 10:51:51 +00:00
|
|
|
|
2019-07-04 08:07:37 +00:00
|
|
|
FROM centos:centos7
|
2021-03-12 19:36:33 +00:00
|
|
|
LABEL org.opencontainers.image.source https://github.com/k8snetworkplumbingwg/multus-cni
|
2019-07-04 08:07:37 +00:00
|
|
|
COPY --from=build /usr/src/multus-cni /usr/src/multus-cni
|
2018-07-27 10:51:51 +00:00
|
|
|
WORKDIR /
|
|
|
|
|
|
|
|
ADD ./images/entrypoint.sh /
|
2018-10-11 17:01:41 +00:00
|
|
|
ENTRYPOINT ["/entrypoint.sh"]
|