CI: Add external plugins to builtin plugins task

This clones a few external plugins to include them in a build. Except
for zeek-kafka, the others are maintained by the Zeek project.

Closes #3535
This commit is contained in:
Arne Welzel 2025-03-30 17:27:24 +02:00
parent 92d2d0c6b8
commit c45625b909
3 changed files with 19 additions and 6 deletions

View file

@ -768,24 +768,35 @@ zeekctl_debian11_task:
upload_zeekctl_testing_artifacts: upload_zeekctl_testing_artifacts:
path: "auxil/zeekctl/testing/.tmp/**" path: "auxil/zeekctl/testing/.tmp/**"
# Test building Zeek with builtin plugins available in include_plugins_debian12_task:
# testing/builtin-plugins/Files/
include_plugins_debian11_task:
cpu: *CPUS cpu: *CPUS
memory: *MEMORY memory: *MEMORY
container: container:
# Debian 11 EOL: June 2026 # Debian 12 (bookworm) EOL: TBD
dockerfile: ci/debian-11/Dockerfile dockerfile: ci/debian-12/Dockerfile
<< : *RESOURCES_TEMPLATE << : *RESOURCES_TEMPLATE
sync_submodules_script: git submodule update --recursive --init sync_submodules_script: git submodule update --recursive --init
fetch_external_plugins_script:
- cd /zeek/testing/builtin-plugins/external && git clone https://github.com/zeek/zeek-perf-support.git
- cd /zeek/testing/builtin-plugins/external && git clone https://github.com/zeek/zeek-more-hashes.git
- cd /zeek/testing/builtin-plugins/external && git clone https://github.com/zeek/zeek-cluster-backend-nats.git
- cd /zeek/testing/builtin-plugins/external && git clone https://github.com/SeisoLLC/zeek-kafka.git
always: always:
ccache_cache: ccache_cache:
folder: /tmp/ccache folder: /tmp/ccache
fingerprint_script: echo builtin-plugins-ccache-$ZEEK_CCACHE_EPOCH-$CIRRUS_TASK_NAME-$CIRRUS_OS fingerprint_script: echo builtin-plugins-ccache-$ZEEK_CCACHE_EPOCH-$CIRRUS_TASK_NAME-$CIRRUS_OS
reupload_on_changes: true reupload_on_changes: true
build_script: ZEEK_CI_CONFIGURE_FLAGS="${ZEEK_CI_CONFIGURE_FLAGS} --include-plugins='/zeek/testing/builtin-plugins/Files/protocol-plugin;/zeek/testing/builtin-plugins/Files/py-lib-plugin;/zeek/testing/builtin-plugins/Files/zeek-version-plugin'" ./ci/build.sh build_script: ZEEK_CI_CONFIGURE_FLAGS="${ZEEK_CI_CONFIGURE_FLAGS} --include-plugins='/zeek/testing/builtin-plugins/Files/protocol-plugin;/zeek/testing/builtin-plugins/Files/py-lib-plugin;/zeek/testing/builtin-plugins/Files/zeek-version-plugin;/zeek/testing/builtin-plugins/external/zeek-perf-support;/zeek/testing/builtin-plugins/external/zeek-more-hashes;/zeek/testing/builtin-plugins/external/zeek-cluster-backend-nats;/zeek/testing/builtin-plugins/external/zeek-kafka'" ./ci/build.sh
test_script: test_script:
- cd testing/builtin-plugins && ../../auxil/btest/btest -d -b -j ${ZEEK_CI_BTEST_JOBS} - cd testing/builtin-plugins && ../../auxil/btest/btest -d -b -j ${ZEEK_CI_BTEST_JOBS}
test_external_plugins_script: |
. /zeek/build/zeek-path-dev.sh
set -ex
# For now, just check if the external plugins are available.
zeek -N Zeek::PerfSupport
zeek -N Zeek::MoreHashes
zeek -N Zeek::Cluster_Backend_NATS
zeek -N Seiso::Kafka
on_failure: on_failure:
upload_include_plugins_testing_artifacts: upload_include_plugins_testing_artifacts:
path: "testing/builtin-plugins/.tmp/**" path: "testing/builtin-plugins/.tmp/**"

View file

@ -20,8 +20,10 @@ RUN apt-get update && apt-get -y install \
git \ git \
jq \ jq \
libkrb5-dev \ libkrb5-dev \
libnats-dev \
libnode-dev \ libnode-dev \
libpcap-dev \ libpcap-dev \
librdkafka-dev \
libssl-dev \ libssl-dev \
libuv1-dev \ libuv1-dev \
make \ make \

View file