From d3a1c333415de245ed5ff20446dcb92a3df49261 Mon Sep 17 00:00:00 2001 From: Einar Lanfranco Date: Thu, 18 Aug 2022 12:13:19 -0300 Subject: [PATCH] fix to support dependenceies for all intelmq default bots --- .docker/intelmq-full-dev/Dockerfile | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.docker/intelmq-full-dev/Dockerfile b/.docker/intelmq-full-dev/Dockerfile index b0e1f30..712aa3b 100644 --- a/.docker/intelmq-full-dev/Dockerfile +++ b/.docker/intelmq-full-dev/Dockerfile @@ -8,6 +8,7 @@ RUN sudo apt-get update \ && sudo apt-get install -y --no-install-recommends \ git \ vim \ + ssh \ && sudo rm -rf /var/lib/apt/lists/* WORKDIR /opt @@ -18,6 +19,11 @@ RUN sudo chmod +x /opt/entrypoint-dev.sh \ RUN sudo chmod +x /opt/install_reqs_and_deploy_bots.sh \ && sudo chown intelmq:intelmq /opt/install_reqs_and_deploy_bots.sh +# This section is just for install all the default bots dependencies +RUN for req in $(find /etc/intelmq/intelmq/bots/ -name "*REQUIREMENTS.txt"); do cat $req >> /tmp/fullrequirements.txt; done +RUN cat /tmp/fullrequirements.txt | sort | uniq > /tmp/orderfullrequirements.txt +RUN cat /tmp/orderfullrequirements.txt |grep -Eo '(^[^#]+)' | xargs -d "\n" -I {} sh -c 'pip3 install "$1"|| exit 0' sh {} + USER intelmq:intelmq ENTRYPOINT [ "/opt/entrypoint-dev.sh" ]