Restructure dockerfile & update libs
Some checks reported errors
continuous-integration/drone/push Build was killed
Some checks reported errors
continuous-integration/drone/push Build was killed
This commit is contained in:
parent
157bcfb920
commit
a9e21882cd
79
Dockerfile
79
Dockerfile
@ -1,12 +1,21 @@
|
|||||||
# Donwnload stage
|
# Base stage with deps
|
||||||
FROM ubuntu:18.04 AS download
|
FROM ubuntu:18.04 AS base
|
||||||
ENV DEBIAN_FRONTEND=noninteractive TZ=Europe/Berlin
|
ENV DEBIAN_FRONTEND=noninteractive TZ=Europe/Berlin
|
||||||
|
|
||||||
# Setup deps
|
# Setup build deps
|
||||||
RUN apt-get update && \
|
RUN apt-get update && \
|
||||||
apt-get -y install --no-install-recommends git openssh-client ca-certificates && \
|
apt-get -y install --no-install-recommends build-essential git cmake autoconf automake unzip libtool-bin pkgconf libssl-dev \
|
||||||
|
python2.7 python-pip python3 python3-pip python-cheetah libcppunit-dev swig uuid-dev libusb-1.0-0-dev \
|
||||||
|
python-mako libzmq3-dev libcomedi-dev python-sip-dev python-six socat \
|
||||||
|
python-numpy python-wxgtk3.0 libzmq3-dev \
|
||||||
|
libqt4-opengl-dev python-qt4 libqwt-dev python-gtk2 python-lxml \
|
||||||
|
git openssh-client ca-certificates && \
|
||||||
rm -rf /var/lib/apt/lists/*
|
rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
|
# Donwnload stage
|
||||||
|
FROM base AS build
|
||||||
|
ENV DEBIAN_FRONTEND=noninteractive TZ=Europe/Berlin
|
||||||
|
|
||||||
# Setup key and server for proprietary code
|
# Setup key and server for proprietary code
|
||||||
ARG PROP_SERVER
|
ARG PROP_SERVER
|
||||||
ARG PROP_SERVER_USER
|
ARG PROP_SERVER_USER
|
||||||
@ -25,56 +34,36 @@ WORKDIR /app
|
|||||||
RUN git clone https://github.com/MOVE-II/move2radio.git && \
|
RUN git clone https://github.com/MOVE-II/move2radio.git && \
|
||||||
cd move2radio && git checkout 6fcbae73359b0618312d222148aba07799a43a47 && git reset --hard && cd .. && \
|
cd move2radio && git checkout 6fcbae73359b0618312d222148aba07799a43a47 && git reset --hard && cd .. && \
|
||||||
git clone git@${PROP_SERVER}:${PROP_DIR_SDR}/ldpc.git move2radio-prop/ldpc && \
|
git clone git@${PROP_SERVER}:${PROP_DIR_SDR}/ldpc.git move2radio-prop/ldpc && \
|
||||||
cd move2radio-prop/ldpc && git checkout 67decffcc74cafff19f7a31f11492fb69c8698eb && git reset --hard && cd ../.. && \
|
|
||||||
git clone git@${PROP_SERVER}:${PROP_DIR_SDR}/gr-ccsds.git move2radio-prop/gr-ccsds && \
|
git clone git@${PROP_SERVER}:${PROP_DIR_SDR}/gr-ccsds.git move2radio-prop/gr-ccsds && \
|
||||||
cd move2radio-prop/gr-ccsds && git checkout c1b8a3fb5d77c02060ddb49b9936097f1d15e536 && git reset --hard && cd ../..
|
git clone git@${PROP_SERVER}:${PROP_DIR_SDR}/libfec.git move2radio-prop/fec
|
||||||
|
|
||||||
|
|
||||||
# Base stage with deps
|
|
||||||
FROM ubuntu:18.04 AS base
|
|
||||||
ENV DEBIAN_FRONTEND=noninteractive TZ=Europe/Berlin
|
|
||||||
|
|
||||||
# Setup build deps
|
|
||||||
RUN apt-get update && \
|
|
||||||
apt-get -y install --no-install-recommends build-essential git cmake autoconf automake unzip libtool-bin pkgconf libssl-dev \
|
|
||||||
python2.7 python-pip python3 python3-pip python-cheetah libcppunit-dev swig uuid-dev libusb-1.0-0-dev \
|
|
||||||
python-mako libzmq3-dev libcomedi-dev python-sip-dev python-six socat \
|
|
||||||
python-numpy python-wxgtk3.0 libzmq3-dev \
|
|
||||||
libqt4-opengl-dev python-qt4 libqwt-dev python-gtk2 python-lxml && \
|
|
||||||
rm -rf /var/lib/apt/lists/*
|
|
||||||
|
|
||||||
|
|
||||||
# Build stage
|
|
||||||
FROM base AS build
|
|
||||||
|
|
||||||
# Copy sources
|
|
||||||
COPY --from=download /app /app
|
|
||||||
|
|
||||||
# Build sources
|
# Build sources
|
||||||
WORKDIR /app/move2radio
|
WORKDIR /app/move2radio
|
||||||
COPY build/CMakeLists.txt /app/move2radio/CMakeLists.txt
|
COPY build/CMakeLists.txt /app/move2radio/CMakeLists.txt
|
||||||
RUN mkdir build
|
RUN mkdir build
|
||||||
WORKDIR /app/move2radio/build
|
WORKDIR /app/move2radio/build
|
||||||
RUN cmake -DAPPIMAGE=OFF -DCONDA_ENV=OFF -DLDPC_OFFLINE=ON -DGR_CCSDS_OFFLINE=ON -DOFFLINE_DEPENDENCY_PATH=/app/move2radio-prop ..
|
RUN cmake -DAPPIMAGE=OFF -DCONDA_ENV=OFF -DLDPC_OFFLINE=ON -DGR_CCSDS_OFFLINE=ON -DFEC_OFFLINE=ON -DOFFLINE_DEPENDENCY_PATH=/app/move2radio-prop ..
|
||||||
RUN make build_gr_osmosdr
|
RUN make build_gr_osmosdr
|
||||||
RUN make build_gr_ccsds
|
# RUN make install_fec build_ldpc build_curlpp
|
||||||
RUN make move2radio
|
# RUN make build_gr_ccsds
|
||||||
|
# RUN make move2radio
|
||||||
|
|
||||||
# Run stage
|
# # Run stage
|
||||||
FROM base AS run
|
# FROM base AS run
|
||||||
|
# ENV DEBIAN_FRONTEND=noninteractive TZ=Europe/Berlin
|
||||||
|
|
||||||
# Copy sources from build stage
|
# # Copy sources from build stage
|
||||||
COPY --from=build /app/move2radio/build/prefix/usr /app/move2radio/build/prefix/usr
|
# COPY --from=build /app/move2radio/build/prefix/usr /app/move2radio/build/prefix/usr
|
||||||
COPY --from=build /app/move2radio/AppDir/move-ii-gr /app/move2radio/AppDir/move-ii-gr
|
# COPY --from=build /app/move2radio/AppDir/move-ii-gr /app/move2radio/AppDir/move-ii-gr
|
||||||
ENV PATH="/app/move2radio/build/prefix/usr/bin:${PATH}" \
|
# ENV PATH="/app/move2radio/build/prefix/usr/bin:${PATH}" \
|
||||||
PYTHONPATH="/app/move2radio/build/prefix/usr/lib/python2.7/dist-packages:${PYTHONPATH}" \
|
# PYTHONPATH="/app/move2radio/build/prefix/usr/lib/python2.7/dist-packages:${PYTHONPATH}" \
|
||||||
LD_LIBRARY_PATH="/app/move2radio/build/prefix/usr/lib:${LD_LIBRARY_PATH}"
|
# LD_LIBRARY_PATH="/app/move2radio/build/prefix/usr/lib:${LD_LIBRARY_PATH}"
|
||||||
|
|
||||||
# Install binaries
|
# # Install binaries
|
||||||
# COPY build/blocks/* app/move2radio/build/prefix/usr/share/gnuradio/grc/blocks/
|
# # COPY build/blocks/* app/move2radio/build/prefix/usr/share/gnuradio/grc/blocks/
|
||||||
COPY build/fakeserver/* /app/fakeserver/
|
# COPY build/fakeserver/* /app/fakeserver/
|
||||||
COPY build/run*.sh /app/
|
# COPY build/run*.sh /app/
|
||||||
RUN chmod 644 app/move2radio/build/prefix/usr/share/gnuradio/grc/blocks/*.xml && \
|
# RUN chmod 644 app/move2radio/build/prefix/usr/share/gnuradio/grc/blocks/*.xml && \
|
||||||
chmod +x /app/run*.sh && ldconfig
|
# chmod +x /app/run*.sh && ldconfig
|
||||||
|
|
||||||
ENTRYPOINT ["/app/run-cli.sh"]
|
# ENTRYPOINT ["/app/run-cli.sh"]
|
Loading…
Reference in New Issue
Block a user