X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=blobdiff_plain;f=Dockerfile;h=6fceabfa478dec652e2f259d4dc25ce3f57bf724;hb=refs%2Fheads%2Fi-release;hp=40de572352ca9bfd7b0a30d169d3aff007bf1dd4;hpb=b1fabdeb006767f851c1379f2966cd6ae935a108;p=ric-plt%2Fo1.git diff --git a/Dockerfile b/Dockerfile index 40de572..6fceabf 100755 --- a/Dockerfile +++ b/Dockerfile @@ -14,7 +14,7 @@ # limitations under the License. #---------------------------------------------------------- -FROM nexus3.o-ran-sc.org:10002/o-ran-sc/bldr-ubuntu18-c-go:1.9.0 AS o1mediator-build +FROM nexus3.o-ran-sc.org:10002/o-ran-sc/bldr-ubuntu20-c-go:1.0.0 AS o1mediator-build RUN apt update && apt install --reinstall -y \ ca-certificates \ @@ -33,15 +33,15 @@ RUN apt-get update -y && apt-get install -y jq \ libev-dev \ libprotobuf-c-dev \ protobuf-c-compiler \ - libssh-dev \ + #libssh-dev \ libssl-dev \ swig \ iputils-ping \ python-dev -ENV GOLANG_VERSION 1.13.10 -RUN wget --quiet https://dl.google.com/go/go$GOLANG_VERSION.linux-amd64.tar.gz \ - && tar xvzf go$GOLANG_VERSION.linux-amd64.tar.gz -C /usr/local -ENV PATH="/usr/local/go/bin:${PATH}" +#ENV GOLANG_VERSION 1.13.10 +#RUN wget --quiet https://dl.google.com/go/go$GOLANG_VERSION.linux-amd64.tar.gz \ +# && tar xvzf go$GOLANG_VERSION.linux-amd64.tar.gz -C /usr/local +#ENV PATH="/usr/local/go/bin:${PATH}" ENV GOPATH="/go" # ====================================================================== @@ -82,7 +82,7 @@ RUN \ make install && make sr_clean && \ ldconfig -# libssh 0.8.0 +# libssh Newest RUN \ cd /opt/dev && \ git clone https://git.libssh.org/projects/libssh.git && cd libssh && \ @@ -113,7 +113,7 @@ RUN \ # ====================================================================== # RMR -ARG RMRVERSION=4.7.4 +ARG RMRVERSION=4.9.4 ARG RMRLIBURL=https://packagecloud.io/o-ran-sc/release/packages/debian/stretch/rmr_${RMRVERSION}_amd64.deb/download.deb ARG RMRDEVURL=https://packagecloud.io/o-ran-sc/release/packages/debian/stretch/rmr-dev_${RMRVERSION}_amd64.deb/download.deb @@ -162,9 +162,9 @@ RUN /usr/local/bin/sysrepoctl -i /go/src/ws/agent/yang/o-ran-sc-ric-alarm-v1.yan CMD ["/bin/bash"] #---------------------------------------------------------- -FROM ubuntu:18.04 as o1mediator +FROM ubuntu:20.04 as o1mediator -RUN apt-get update -y && apt-get install -y jq \ +RUN apt-get update -y && DEBIAN_FRONTEND=noninteractive apt-get install -y jq \ net-tools \ tcpdump \ netcat \ @@ -172,21 +172,27 @@ RUN apt-get update -y && apt-get install -y jq \ nano \ supervisor \ openssl \ - python-pip \ + python3-pip \ libpcre3-dev \ pkg-config \ libavl-dev \ libev-dev \ libprotobuf-c-dev \ protobuf-c-compiler \ - libssh-dev \ + #libssh-dev \ libssl-dev \ swig \ python-dev \ - && pip install supervisor-stdout \ - && pip install psutil \ + wget \ + && pip3 install supervisor-stdout \ + && pip3 install psutil \ && apt-get clean +# Install psutil for python2.X +RUN wget https://bootstrap.pypa.io/pip/2.7/get-pip.py \ + && python get-pip.py \ + && python -m pip install psutil + RUN rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* # update password policy @@ -217,6 +223,10 @@ COPY --from=o1mediator-build /usr/local/bin/ /usr/local/bin/ COPY --from=o1mediator-build /usr/local/lib/ /usr/local/lib/ COPY --from=o1mediator-build /usr/local/bin/kubectl /usr/local/bin/kubectl +COPY --from=o1mediator-build /usr/include/libssh/ /usr/include/libssh/ +COPY --from=o1mediator-build /usr/lib/x86_64-linux-gnu/libssh.so.4.* /usr/lib/x86_64-linux-gnu/ +RUN ln -s libssh.so.4 /usr/lib/x86_64-linux-gnu/libssh.so + RUN ldconfig # copy yang models with data