# syntax=docker/dockerfile:1.3 FROM registry.fedoraproject.org/fedora-minimal:35 ARG BUILD_DATE ARG VCS_REF LABEL description="Container image mainly used for CI testing of C/C++ programs on Fedora" LABEL org.label-schema.build-date=$BUILD_DATE \ org.label-schema.vcs-url="https://git.dotya.ml/wanderer/docker-fedora-cpp.git" \ org.label-schema.vcs-ref=$VCS_REF \ org.label-schema.license=GPL-3.0 RUN cat /etc/dnf/dnf.conf; \ microdnf --refresh upgrade -y RUN microdnf install --nodocs --setopt install_weak_deps=0 -y \ git \ ninja-build \ make \ cmake \ automake \ gcc \ gcc-c++ \ libgcc \ libstdc++-devel \ libstdc++-static \ glibc-devel \ binutils \ flex \ bison \ openmpi-devel \ which \ file \ grpc-cli \ grpc-cpp \ grpc-devel \ grpc-plugins \ protobuf-c-devel \ protobuf-c-compiler \ protobuf-compiler \ cppunit \ log4cpp-devel \ json-c-devel \ capnproto-devel \ capnproto-libs \ libpcap-devel \ hiredis-devel \ mongo-c-driver-devel \ mongo-c-driver-libs \ boost-devel \ boost-atomic \ boost-chrono \ boost-date-time \ boost-system \ boost-program-options \ boost-regex \ boost-thread \ libtool \ autoconf \ pkgconf \ kernel-devel \ ncurses-c++-libs \ ncurses-devel \ ncurses-libs \ ncurses-static \ numactl-devel \ numactl-libs \ && microdnf clean all -y # nDPI will by default (left unchanged) be installed with prefix "/usr/local". # this makes sure the results get picked up in subsequent linkings against it. RUN printf "/usr/local/lib\n" >> /etc/ld.so.conf.d/local.conf && /usr/sbin/ldconfig # see https://git.dotya.ml/wanderer/docker-fedora-cpp/issues/1 # # building nDPI would fail with plain RUN and kaniko. # having it wrapped in 'bash -c' helped RUN bash -c 'export MAKEFLAGS="$MAKEFLAGS -j$(nproc)" && printf "$MAKEFLAGS\n"; \ export PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/sbin:$PATH"; \ git clone https://github.com/ntop/nDPI.git /tmp/nDPI && \ cd /tmp/nDPI ; \ git checkout 1.7; \ ./autogen.sh && \ ./configure && \ make && \ make install && \ make clean && \ git switch - ; \ ./autogen.sh && \ ./configure && \ make && \ make install' RUN if [ -f /tmp/nDPI/config.log ]; then cat /tmp/nDPI/config.log; fi; \ rm -rf /tmp/nDPI