Bump version and fix cloning when specific a specific commit

pull/1/head
Stefano Ortolani 2023-03-28 14:37:13 +01:00
parent 3f7ea9ae15
commit 8d7031e42c
3 changed files with 10 additions and 13 deletions

View File

@ -22,13 +22,10 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
RUN mkdir /wheel
WORKDIR /srv
RUN git clone --branch ${MODULES_TAG} --depth 1 https://github.com/MISP/misp-modules.git /srv/misp-modules
RUN if [ ! -z ${MODULES_COMMIT} ]; then cd /srv/misp-modules && git checkout ${MODULES_COMMIT}; fi; \
# Fixed in master - even though __init__.py is not mandatory in py3, wheels skip packages without it
touch /srv/misp-modules/misp_modules/modules/action_mod/_utils/__init__.py; \
# Fixed in master - missing dependencies
echo "Jinja2==3.1.2\nmattermostdriver==7.3.2" >> /srv/misp-modules/REQUIREMENTS; \
cd /srv/misp-modules || exit; sed -i 's/-e //g' REQUIREMENTS; pip3 wheel -r REQUIREMENTS --no-cache-dir -w /wheel/
RUN if [ ! -z ${MODULES_COMMIT} ]; then \
git clone https://github.com/MISP/misp-modules.git /srv/misp-modules && cd /srv/misp-modules && git checkout ${MODULES_COMMIT}; \
else git clone --branch ${MODULES_TAG} --depth 1 https://github.com/MISP/misp-modules.git /srv/misp-modules; fi
RUN cd /srv/misp-modules || exit; sed -i 's/-e //g' REQUIREMENTS; pip3 wheel -r REQUIREMENTS --no-cache-dir -w /wheel/
RUN git clone --depth 1 https://github.com/stricaud/faup.git /srv/faup; \
cd /srv/faup/build || exit; cmake .. && make install; \

View File

@ -133,10 +133,10 @@ ARG PHP_VER
# MISP code
# Download MISP using git in the /var/www/ directory.
RUN git clone --branch ${MISP_TAG} --depth 1 https://github.com/MISP/MISP.git /var/www/MISP
RUN if [ ! -z ${MISP_COMMIT} ]; then cd /var/www/MISP && git checkout ${MISP_COMMIT}; fi; \
# We build the MISP modules outside, so we don't need to grab those submodules
cd /var/www/MISP/app || exit; git submodule update --init --recursive .; \
RUN if [ ! -z ${MISP_COMMIT} ]; then \
git clone https://github.com/MISP/MISP.git /var/www/MISP && cd /var/www/MISP && git checkout ${MISP_COMMIT}; \
else git clone --branch ${MISP_TAG} --depth 1 https://github.com/MISP/MISP.git /var/www/MISP; fi
RUN cd /var/www/MISP/app || exit; git submodule update --init --recursive .; \
# Remove some old and broken links that pollute the log files
rm -rf /var/www/MISP/INSTALL/old

View File

@ -1,5 +1,5 @@
MISP_TAG=v2.4.168
MODULES_TAG=v2.4.165
MISP_TAG=v2.4.169
MODULES_TAG=v2.4.169
PHP_VER=20190902
# MISP_COMMIT takes precedence over MISP_TAG
# MISP_COMMIT=c56d537