diff options
author | Kuralamudhan Ramakrishnan <kuralamudhan.ramakrishnan@intel.com> | 2020-09-16 15:14:13 -0700 |
---|---|---|
committer | Kuralamudhan Ramakrishnan <kuralamudhan.ramakrishnan@intel.com> | 2020-09-17 17:10:02 -0700 |
commit | 2efea1a12076d2ca11dedfd932fdfc0893e1d288 (patch) | |
tree | 104197707223e7b4fa95bb38da5d68c092ff6c8f /build | |
parent | 69b6bceec76caea07f95ba5cc372205c16e0e11b (diff) |
adding centos 8 dockerfile for ovn & ovn4k8s-nfv images
Signed-off-by: Kuralamudhan Ramakrishnan <kuralamudhan.ramakrishnan@intel.com>
Change-Id: Ib161ea39fc6da9a7649142271a781b3140068d15
Diffstat (limited to 'build')
-rw-r--r-- | build/Dockerfile.centos | 49 | ||||
-rw-r--r-- | build/Dockerfile.ubuntu (renamed from build/Dockerfile) | 0 |
2 files changed, 49 insertions, 0 deletions
diff --git a/build/Dockerfile.centos b/build/Dockerfile.centos new file mode 100644 index 0000000..0b0de04 --- /dev/null +++ b/build/Dockerfile.centos @@ -0,0 +1,49 @@ +FROM centos:8 + +ARG HTTP_PROXY=${HTTP_PROXY} +ARG HTTPS_PROXY=${HTTPS_PROXY} + +ENV http_proxy $HTTP_PROXY +ENV https_proxy $HTTPS_PROXY +ENV no_proxy $NO_PROXY + +RUN yum update -y && yum install -y -qq make curl net-tools iproute iptables \ + wget nc jq ipset unbound unbound-devel + +RUN mkdir -p /opt/ovn4nfv-k8s-plugin/ovs/rpm/rpmbuild/RPMS/x86_64 +RUN bash -xc "\ +pushd /opt/ovn4nfv-k8s-plugin/ovs/rpm/rpmbuild/RPMS/x86_64; \ +wget -q -nv -O- https://api.github.com/repos/akraino-icn/ovs/releases/tags/v2.14.0 2>/dev/null | jq -r '.assets[] | select(.browser_download_url | contains("\""rpm"\"")) | .browser_download_url' | wget -i -; \ +popd; \ +" +RUN rpm -ivh --nodeps /opt/ovn4nfv-k8s-plugin/ovs/rpm/rpmbuild/RPMS/x86_64/*.rpm + +RUN mkdir -p /opt/ovn4nfv-k8s-plugin/ovn/rpm/rpmbuild/RPMS/x86_64 +RUN bash -xc "\ +pushd /opt/ovn4nfv-k8s-plugin/ovn/rpm/rpmbuild/RPMS/x86_64; \ +wget -q -nv -O- https://api.github.com/repos/akraino-icn/ovn/releases/tags/v20.06.0 2>/dev/null | jq -r '.assets[] | select(.browser_download_url | contains("\""rpm"\"")) | .browser_download_url' | wget -i -; \ +popd; \ +" +RUN rpm -ivh --nodeps /opt/ovn4nfv-k8s-plugin/ovn/rpm/rpmbuild/RPMS/x86_64/*.rpm + +ENV GOLANG_VERSION 1.14.1 +RUN curl -sSL https://storage.googleapis.com/golang/go$GOLANG_VERSION.linux-amd64.tar.gz \ + | tar -v -C /usr/local -xz + +ENV PATH /usr/local/go/bin:$PATH +RUN mkdir -p /go/src /go/bin && chmod -R 777 /go +ENV GOROOT /usr/local/go +ENV GOPATH /go +ENV PATH /go/bin:$PATH + +WORKDIR /go/src/github.com/opnfv/ovn4nfv-k8s-plugin +COPY . . +RUN make all + +ENV OPERATOR=/usr/local/bin/nfn-operator \ + AGENT=/usr/local/bin/nfn-agent \ + USER_UID=1001 \ + USER_NAME=nfn-operator + +RUN cp -r build/bin/* /usr/local/bin/ +ENTRYPOINT ["entrypoint"] diff --git a/build/Dockerfile b/build/Dockerfile.ubuntu index eefdeb3..eefdeb3 100644 --- a/build/Dockerfile +++ b/build/Dockerfile.ubuntu |