From 0f68ad73e2d1fc48be45249e8c49889b1d5b310f Mon Sep 17 00:00:00 2001 From: Tim Wojtulewicz Date: Tue, 24 Oct 2023 15:42:21 -0700 Subject: [PATCH 01/14] CI: Pass -A flag to btest for cluster-testing builds (cherry picked from commit ac7685c679cdb6d61768ac20449175eaaaacc34c) --- .cirrus.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.cirrus.yml b/.cirrus.yml index 6f0a54b0b2..c4c50a055c 100644 --- a/.cirrus.yml +++ b/.cirrus.yml @@ -683,7 +683,7 @@ cluster_testing_docker_builder: test_script: # Invoke btest directly here. This mirrors ci/test.sh, ensures we don't # accidentally build a Docker image, and enables console-level output: - - cd testing/external/zeek-testing-cluster && ../../../auxil/btest/btest -d -b -j ${ZEEK_CI_BTEST_JOBS} + - cd testing/external/zeek-testing-cluster && ../../../auxil/btest/btest -A -d -b -j ${ZEEK_CI_BTEST_JOBS} on_failure: upload_cluster_testing_artifacts: path: "testing/external/zeek-testing-cluster/.tmp/**" From 733ff2632cc6e1e0a129ce288a213518b52957f7 Mon Sep 17 00:00:00 2001 From: Benjamin Bannier Date: Thu, 26 Oct 2023 14:47:59 +0200 Subject: [PATCH 02/14] Install libmaxminddb in macOS CI (cherry picked from commit dfba2d6df707840cabf822d70354f9e2e635b863) --- ci/macos/prepare.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ci/macos/prepare.sh b/ci/macos/prepare.sh index 6d3909a90d..52c4472272 100755 --- a/ci/macos/prepare.sh +++ b/ci/macos/prepare.sh @@ -7,7 +7,7 @@ set -x brew update brew upgrade cmake -brew install openssl@3 swig bison flex ccache +brew install openssl@3 swig bison flex ccache libmaxminddb python3 -m pip install --user websockets # Brew doesn't create the /opt/homebrew/opt/openssl symlink if you install From b4948411ba312a9f290f9d2e784f5fd1347873ac Mon Sep 17 00:00:00 2001 From: Benjamin Bannier Date: Thu, 26 Oct 2023 15:13:02 +0200 Subject: [PATCH 03/14] Fix tests so they work both with GNU and BSD tools The GNU and BSD versions of `touch` and `truncate` allow slightly different arguments, change the tests so they work in both versions. (cherry picked from commit caaffd0324ac0557ba4c5ce0290d07a4d013a735) --- .../core.mmdb.temporary-error/reporter.log | 8 ++-- testing/btest/core/mmdb/reopen.zeek | 13 +++++-- testing/btest/core/mmdb/temporary-error.zeek | 38 +++++++++++++------ 3 files changed, 41 insertions(+), 18 deletions(-) diff --git a/testing/btest/Baseline/core.mmdb.temporary-error/reporter.log b/testing/btest/Baseline/core.mmdb.temporary-error/reporter.log index 5ec6a3e3ec..298339c2b6 100644 --- a/testing/btest/Baseline/core.mmdb.temporary-error/reporter.log +++ b/testing/btest/Baseline/core.mmdb.temporary-error/reporter.log @@ -3,15 +3,15 @@ ts level message location 1299470395.000000 Reporter::INFO Modification time change detected for MaxMind DB [.<...>/GeoLite2-ASN.mmdb] , line 1 1299470395.000000 Reporter::INFO Closing stale MaxMind DB [.<...>/GeoLite2-ASN.mmdb] , line 1 1299470395.000000 Reporter::INFO Failed to open MaxMind DB: .<...>/GeoLite2-ASN.mmdb [The MaxMind DB file contains invalid metadata] , line 1 -1299470395.000000 Reporter::ERROR Failed to open GeoIP ASN database (lookup_autonomous_system(128.3.0.1)) <...>/temporary-error.zeek, line 83 +1299470395.000000 Reporter::ERROR Failed to open GeoIP ASN database (lookup_autonomous_system(128.3.0.1)) <...>/temporary-error.zeek, line 99 1299470395.000000 Reporter::INFO Modification time change detected for MaxMind DB [.<...>/GeoLite2-City.mmdb] , line 1 1299470395.000000 Reporter::INFO Closing stale MaxMind DB [.<...>/GeoLite2-City.mmdb] , line 1 1299470395.000000 Reporter::INFO Failed to open MaxMind DB: .<...>/GeoLite2-City.mmdb [The MaxMind DB file contains invalid metadata] , line 1 -1299470395.000000 Reporter::ERROR Failed to open GeoIP location database (lookup_location(128.3.0.1)) <...>/temporary-error.zeek, line 84 +1299470395.000000 Reporter::ERROR Failed to open GeoIP location database (lookup_location(128.3.0.1)) <...>/temporary-error.zeek, line 100 1299473995.000000 Reporter::INFO Closing stale MaxMind DB [.<...>/GeoLite2-ASN.mmdb] , line 1 -1299473995.000000 Reporter::ERROR Failed to open GeoIP ASN database (lookup_autonomous_system(128.3.0.1)) <...>/temporary-error.zeek, line 83 +1299473995.000000 Reporter::ERROR Failed to open GeoIP ASN database (lookup_autonomous_system(128.3.0.1)) <...>/temporary-error.zeek, line 99 1299473995.000000 Reporter::INFO Closing stale MaxMind DB [.<...>/GeoLite2-City.mmdb] , line 1 -1299473995.000000 Reporter::ERROR Failed to open GeoIP location database (lookup_location(128.3.0.1)) <...>/temporary-error.zeek, line 84 +1299473995.000000 Reporter::ERROR Failed to open GeoIP location database (lookup_location(128.3.0.1)) <...>/temporary-error.zeek, line 100 1299477595.000000 Reporter::INFO Inode change detected for MaxMind DB [.<...>/GeoLite2-ASN.mmdb] , line 1 1299477595.000000 Reporter::INFO Closing stale MaxMind DB [.<...>/GeoLite2-ASN.mmdb] , line 1 1299477595.000000 Reporter::INFO Inode change detected for MaxMind DB [.<...>/GeoLite2-City.mmdb] , line 1 diff --git a/testing/btest/core/mmdb/reopen.zeek b/testing/btest/core/mmdb/reopen.zeek index d9c120c8dc..f764097e85 100644 --- a/testing/btest/core/mmdb/reopen.zeek +++ b/testing/btest/core/mmdb/reopen.zeek @@ -14,17 +14,24 @@ redef mmdb_dir = "./mmdb"; global pkt = 0; +function timestamp(n: count): string + { + assert n <= 60; + return fmt("2020-01-01T00:%s:00", n); + } + event new_packet(c: connection, p: pkt_hdr) { ++pkt; - # Set MMDB's modification time to current network time. + + # Increment MMDB's modification time. local asn_fn = safe_shell_quote(mmdb_dir + "/GeoLite2-ASN.mmdb"); local city_fn = safe_shell_quote(mmdb_dir + "/GeoLite2-City.mmdb"); - if ( ! piped_exec(fmt("touch -d @%s %s", network_time(), asn_fn), "") ) + if ( ! piped_exec(fmt("touch -d %s %s", timestamp(pkt), asn_fn), "") ) exit(1); - if ( ! piped_exec(fmt("touch -d @%s %s", network_time(), city_fn), "") ) + if ( ! piped_exec(fmt("touch -d %s %s", timestamp(pkt), city_fn), "") ) exit(1); print network_time(), pkt, 128.3.0.1, "asn", lookup_autonomous_system(128.3.0.1); diff --git a/testing/btest/core/mmdb/temporary-error.zeek b/testing/btest/core/mmdb/temporary-error.zeek index 0a5102535c..a425732726 100644 --- a/testing/btest/core/mmdb/temporary-error.zeek +++ b/testing/btest/core/mmdb/temporary-error.zeek @@ -15,16 +15,32 @@ redef mmdb_dir = "./mmdb"; global pkt = 0; +global asn_fn = safe_shell_quote(mmdb_dir + "/GeoLite2-ASN.mmdb"); +global city_fn = safe_shell_quote(mmdb_dir + "/GeoLite2-City.mmdb"); + +global asn_fn_backup = safe_shell_quote(mmdb_dir + "-backup/GeoLite2-ASN.mmdb"); +global city_fn_backup = safe_shell_quote(mmdb_dir + "-backup/GeoLite2-City.mmdb"); + +function timestamp(n: count): string + { + assert n <= 60; + return fmt("2020-01-01T00:%s:00", n); + } + +event zeek_init() + { + # Set the initial modification time for the MMDBs. + for ( db in vector(asn_fn, city_fn, asn_fn_backup, city_fn_backup) ) + { + if ( ! piped_exec(fmt("test -f %s && touch -d %s %s", db, timestamp(pkt), db), "") ) + exit(1); + } + } + event new_packet(c: connection, p: pkt_hdr) { ++pkt; - local asn_fn = safe_shell_quote(mmdb_dir + "/GeoLite2-ASN.mmdb"); - local city_fn = safe_shell_quote(mmdb_dir + "/GeoLite2-City.mmdb"); - - local asn_fn_backup = safe_shell_quote(mmdb_dir + "-backup/GeoLite2-ASN.mmdb"); - local city_fn_backup = safe_shell_quote(mmdb_dir + "-backup/GeoLite2-City.mmdb"); - if ( pkt == 1 ) { print "start"; @@ -32,10 +48,10 @@ event new_packet(c: connection, p: pkt_hdr) if ( pkt == 2 ) { print "corrupting db"; - if ( ! piped_exec(fmt("truncate --size=8 %s", asn_fn), "") ) + if ( ! piped_exec(fmt("truncate -s 8 %s", asn_fn), "") ) exit(1); - if ( ! piped_exec(fmt("truncate --size=8 %s", city_fn), "") ) + if ( ! piped_exec(fmt("truncate -s 8 %s", city_fn), "") ) exit(1); } else if ( pkt == 4 ) @@ -73,11 +89,11 @@ event new_packet(c: connection, p: pkt_hdr) exit(1); } - # Set MMDB's modification time to current network time for predictability. - if ( ! piped_exec(fmt("test -f %s && touch -d @%s %s", asn_fn, network_time(), asn_fn), "") ) + # Increment MMDB's modification time. + if ( ! piped_exec(fmt("test -f %s && touch -d %s %s", asn_fn, timestamp(pkt), asn_fn), "") ) exit(1); - if ( ! piped_exec(fmt("test -f %s && touch -d @%s %s", city_fn, network_time(), city_fn), "") ) + if ( ! piped_exec(fmt("test -f %s && touch -d %s %s", city_fn, timestamp(pkt), city_fn), "") ) exit(1); print network_time(), pkt, 128.3.0.1, "asn", lookup_autonomous_system(128.3.0.1); From 1de8cfcb4a12b1ef8015a206860fc39ea7bcf4c5 Mon Sep 17 00:00:00 2001 From: Tim Wojtulewicz Date: Mon, 6 Nov 2023 11:09:44 -0700 Subject: [PATCH 04/14] CI: Add macOS Sonoma build, remove macOS Monterey build (cherry picked from commit 35ca1e88c7f1398c37bcbc4e20700a2aff2c4169) --- .cirrus.yml | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/.cirrus.yml b/.cirrus.yml index c4c50a055c..9ae0faf5bd 100644 --- a/.cirrus.yml +++ b/.cirrus.yml @@ -350,6 +350,13 @@ alpine_task: # Apple doesn't publish official long-term support timelines. # We aim to support both the current and previous macOS release. +macos_sonoma_task: + macos_instance: + image: ghcr.io/cirruslabs/macos-sonoma-base:latest + prepare_script: ./ci/macos/prepare.sh + << : *CI_TEMPLATE + << : *MACOS_ENVIRONMENT + macos_ventura_task: macos_instance: image: ghcr.io/cirruslabs/macos-ventura-base:latest @@ -357,14 +364,6 @@ macos_ventura_task: << : *CI_TEMPLATE << : *MACOS_ENVIRONMENT -macos_monterey_task: - macos_instance: - image: ghcr.io/cirruslabs/macos-monterey-base:latest - prepare_script: ./ci/macos/prepare.sh - << : *CI_TEMPLATE - << : *MACOS_ENVIRONMENT - << : *SKIP_TASK_ON_PR - # FreeBSD EOL timelines: https://www.freebsd.org/security/#sup freebsd14_task: freebsd_instance: From 71eb63cff086b12da45a9b2a2a40a084d2eb75a7 Mon Sep 17 00:00:00 2001 From: Tim Wojtulewicz Date: Mon, 6 Nov 2023 11:29:44 -0700 Subject: [PATCH 05/14] CI: Use other base64 options on macOS Sonoma too (cherry picked from commit b1e63ffd268cdb2cd28098a0a8578a3038be8fd4) --- ci/init-external-repos.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ci/init-external-repos.sh b/ci/init-external-repos.sh index ce2d3f4a6d..7f27f582be 100755 --- a/ci/init-external-repos.sh +++ b/ci/init-external-repos.sh @@ -51,8 +51,8 @@ if [[ -n "${CIRRUS_CI}" ]] && [[ "${CIRRUS_REPO_OWNER}" == "zeek" ]] && [[ ! -d banner "Trying to clone zeek-testing-private git repo" echo "${ZEEK_TESTING_PRIVATE_SSH_KEY}" >cirrus_key.b64 - if [ "${CIRRUS_TASK_NAME}" == "macos_ventura" ]; then - # The base64 command provided with macOS Ventura requires an argument + if [ "${CIRRUS_TASK_NAME}" == "macos_ventura" -o "${CIRRUS_TASK_NAME}" == "macos_sonoma" ]; then + # The base64 command provided with macOS Ventura/Sonoma requires an argument # to pass the input filename base64 -d -i cirrus_key.b64 >cirrus_key else From 28b720f8c64af5fd822b1058b8cd9ee5952d899b Mon Sep 17 00:00:00 2001 From: Tim Wojtulewicz Date: Fri, 10 Nov 2023 14:42:01 -0700 Subject: [PATCH 06/14] CI: Install missing packages on opensuse (cherry picked from commit a3ad1a24f11770d5b8c39af1671beb5d2b4c65b2) --- ci/opensuse-leap-15.4/Dockerfile | 1 + ci/opensuse-leap-15.5/Dockerfile | 1 + ci/opensuse-tumbleweed/Dockerfile | 5 ++++- 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/ci/opensuse-leap-15.4/Dockerfile b/ci/opensuse-leap-15.4/Dockerfile index 4c48f49e05..8f95ebb085 100644 --- a/ci/opensuse-leap-15.4/Dockerfile +++ b/ci/opensuse-leap-15.4/Dockerfile @@ -19,6 +19,7 @@ RUN zypper addrepo https://download.opensuse.org/repositories/openSUSE:Leap:15.4 libopenssl-devel \ libpcap-devel \ make \ + openssh \ python39 \ python39-devel \ python39-pip \ diff --git a/ci/opensuse-leap-15.5/Dockerfile b/ci/opensuse-leap-15.5/Dockerfile index 3fee52ef48..605412a885 100644 --- a/ci/opensuse-leap-15.5/Dockerfile +++ b/ci/opensuse-leap-15.5/Dockerfile @@ -19,6 +19,7 @@ RUN zypper addrepo https://download.opensuse.org/repositories/openSUSE:Leap:15.5 libopenssl-devel \ libpcap-devel \ make \ + openssh \ python311 \ python311-devel \ python311-pip \ diff --git a/ci/opensuse-tumbleweed/Dockerfile b/ci/opensuse-tumbleweed/Dockerfile index 8d7cfc0748..f701475504 100644 --- a/ci/opensuse-tumbleweed/Dockerfile +++ b/ci/opensuse-tumbleweed/Dockerfile @@ -10,6 +10,7 @@ RUN zypper modifyrepo --disable repo-openh264 || true RUN zypper refresh \ && zypper in -y \ + awk \ bison \ ccache \ cmake \ @@ -24,9 +25,11 @@ RUN zypper refresh \ libopenssl-devel \ libpcap-devel \ make \ + openssh \ python3 \ python3-devel \ python3-pip \ + python3-websockets \ swig \ tar \ util-linux \ @@ -34,4 +37,4 @@ RUN zypper refresh \ zlib-devel \ && rm -rf /var/cache/zypp -RUN pip3 install websockets junit2html +RUN pip3 install --break-system-packages junit2html From cc568d87b723aebe2017a5faa6c082e54359e5af Mon Sep 17 00:00:00 2001 From: Christian Kreibich Date: Fri, 8 Dec 2023 18:16:34 -0800 Subject: [PATCH 07/14] CI: drop Fedora 37, add Fedora 39 This makes 39 the ony to run at all times, and 38 one to run only with fullci. (cherry picked from commit ee8cc77050e39aea18f2da144dc8108110bb42dc) --- .cirrus.yml | 14 +++++++------- ci/{fedora-37 => fedora-39}/Dockerfile | 4 ++-- 2 files changed, 9 insertions(+), 9 deletions(-) rename ci/{fedora-37 => fedora-39}/Dockerfile (92%) diff --git a/.cirrus.yml b/.cirrus.yml index 9ae0faf5bd..9055bf415c 100644 --- a/.cirrus.yml +++ b/.cirrus.yml @@ -166,19 +166,19 @@ env: # Linux EOL timelines: https://linuxlifecycle.com/ # Fedora (~13 months): https://fedoraproject.org/wiki/Fedora_Release_Life_Cycle +fedora39_task: + container: + # Fedora 39 EOL: Around Nov 2024 + dockerfile: ci/fedora-39/Dockerfile + << : *RESOURCES_TEMPLATE + << : *CI_TEMPLATE + fedora38_task: container: # Fedora 38 EOL: Around May 2024 dockerfile: ci/fedora-38/Dockerfile << : *RESOURCES_TEMPLATE << : *CI_TEMPLATE - -fedora37_task: - container: - # Fedora 37 EOL: Around Dec 2024 - dockerfile: ci/fedora-37/Dockerfile - << : *RESOURCES_TEMPLATE - << : *CI_TEMPLATE << : *SKIP_TASK_ON_PR centosstream9_task: diff --git a/ci/fedora-37/Dockerfile b/ci/fedora-39/Dockerfile similarity index 92% rename from ci/fedora-37/Dockerfile rename to ci/fedora-39/Dockerfile index a5955c5ef4..3b9177415a 100644 --- a/ci/fedora-37/Dockerfile +++ b/ci/fedora-39/Dockerfile @@ -1,8 +1,8 @@ -FROM fedora:37 +FROM fedora:39 # A version field to invalidate Cirrus's build cache when needed, as suggested in # https://github.com/cirruslabs/cirrus-ci-docs/issues/544#issuecomment-566066822 -ENV DOCKERFILE_VERSION 20230801 +ENV DOCKERFILE_VERSION 20231208 RUN dnf -y install \ bison \ From 8ea99503e8fa824e6bcede4768189196db0971a8 Mon Sep 17 00:00:00 2001 From: Christian Kreibich Date: Fri, 8 Dec 2023 18:30:32 -0800 Subject: [PATCH 08/14] CI: distro EOL comment tweaks (cherry picked from commit eb1c4bf019f6a39f1d76de717eee1b34cdc50378) --- .cirrus.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.cirrus.yml b/.cirrus.yml index 9055bf415c..b21fd2a06b 100644 --- a/.cirrus.yml +++ b/.cirrus.yml @@ -208,7 +208,7 @@ centos7_task: debian12_task: container: - # Debian 12 (bookworm) EOL: (not yet released) + # Debian 12 (bookworm) EOL: TBD dockerfile: ci/debian-12/Dockerfile << : *RESOURCES_TEMPLATE << : *CI_TEMPLATE @@ -250,7 +250,7 @@ debian10_task: opensuse_leap_15_4_task: container: - # Opensuse Leap 15.4 EOL: ~Nov 2023 + # Opensuse Leap 15.4 EOL: ~Dec 2023 dockerfile: ci/opensuse-leap-15.4/Dockerfile << : *RESOURCES_TEMPLATE << : *CI_TEMPLATE From b3b584936c770dbe6233b91cf7c83d21c19558bf Mon Sep 17 00:00:00 2001 From: Christian Kreibich Date: Fri, 8 Dec 2023 18:43:57 -0800 Subject: [PATCH 09/14] CI: FreeBSD 14 is out now, 12 is about to EOL. (cherry picked from commit 18b8e6d6bceb4492d842d9bacbd3ad9dfbdd7702) --- .cirrus.yml | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/.cirrus.yml b/.cirrus.yml index b21fd2a06b..f9ad98279e 100644 --- a/.cirrus.yml +++ b/.cirrus.yml @@ -367,10 +367,8 @@ macos_ventura_task: # FreeBSD EOL timelines: https://www.freebsd.org/security/#sup freebsd14_task: freebsd_instance: - # We don't support FreeBSD 14 yet, this is a purely informative task - image_family: freebsd-14-0-snap - allow_failures: true - skip_notification: true + # FreeBSD 14 EOL: Nov 30 2028 + image_family: freebsd-14-0 << : *FREEBSD_RESOURCES_TEMPLATE prepare_script: ./ci/freebsd/prepare.sh From 6262752cf5488f8cc1cf867af172bfb6f87d08c2 Mon Sep 17 00:00:00 2001 From: Christian Kreibich Date: Wed, 13 Dec 2023 22:03:25 -0800 Subject: [PATCH 10/14] CI: Drop openSUSE Leap 15.4, about to EOL. (cherry picked from commit ddd56b9ad7171a9f8ee3de03bc362223f2fad0fc) --- .cirrus.yml | 10 -------- ci/opensuse-leap-15.4/Dockerfile | 39 -------------------------------- 2 files changed, 49 deletions(-) delete mode 100644 ci/opensuse-leap-15.4/Dockerfile diff --git a/.cirrus.yml b/.cirrus.yml index f9ad98279e..f600ee6fe4 100644 --- a/.cirrus.yml +++ b/.cirrus.yml @@ -248,16 +248,6 @@ debian10_task: << : *RESOURCES_TEMPLATE << : *CI_TEMPLATE -opensuse_leap_15_4_task: - container: - # Opensuse Leap 15.4 EOL: ~Dec 2023 - dockerfile: ci/opensuse-leap-15.4/Dockerfile - << : *RESOURCES_TEMPLATE - << : *CI_TEMPLATE - << : *SKIP_TASK_ON_PR - env: - ZEEK_CI_CONFIGURE_FLAGS: *NO_SPICY_CONFIG - opensuse_leap_15_5_task: container: # Opensuse Leap 15.5 EOL: ~Dec 2024 diff --git a/ci/opensuse-leap-15.4/Dockerfile b/ci/opensuse-leap-15.4/Dockerfile deleted file mode 100644 index 8f95ebb085..0000000000 --- a/ci/opensuse-leap-15.4/Dockerfile +++ /dev/null @@ -1,39 +0,0 @@ -FROM opensuse/leap:15.4 - -# A version field to invalidate Cirrus's build cache when needed, as suggested in -# https://github.com/cirruslabs/cirrus-ci-docs/issues/544#issuecomment-566066822 -ENV DOCKERFILE_VERSION 20230801 - -RUN zypper addrepo https://download.opensuse.org/repositories/openSUSE:Leap:15.4:Update/standard/openSUSE:Leap:15.4:Update.repo \ - && zypper refresh \ - && zypper in -y \ - bison \ - ccache \ - cmake \ - curl \ - flex \ - gcc10 \ - gcc10-c++ \ - git \ - gzip \ - libopenssl-devel \ - libpcap-devel \ - make \ - openssh \ - python39 \ - python39-devel \ - python39-pip \ - swig \ - tar \ - which \ - zlib-devel \ - && rm -rf /var/cache/zypp - -RUN update-alternatives --install /usr/bin/pip3 pip3 /usr/bin/pip3.9 100 -RUN update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.9 100 -RUN update-alternatives --install /usr/bin/python3-config python3-config /usr/bin/python3.9-config 100 - -RUN pip3 install websockets junit2html - -RUN update-alternatives --install /usr/bin/cc cc /usr/bin/gcc-10 100 -RUN update-alternatives --install /usr/bin/c++ c++ /usr/bin/g++-10 100 From 60342c06982fb27a10e7c73f1269944c4242382f Mon Sep 17 00:00:00 2001 From: Christian Kreibich Date: Thu, 14 Dec 2023 15:35:13 -0800 Subject: [PATCH 11/14] CI: Bump Ubuntu 23.04 to 23.10 (cherry picked from commit 866d4b4127ccfd8904f8867b468babd330dd6d52) --- .cirrus.yml | 4 ++-- ci/{ubuntu-23.04 => ubuntu-23.10}/Dockerfile | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) rename ci/{ubuntu-23.04 => ubuntu-23.10}/Dockerfile (97%) diff --git a/.cirrus.yml b/.cirrus.yml index f600ee6fe4..43f205115c 100644 --- a/.cirrus.yml +++ b/.cirrus.yml @@ -266,8 +266,8 @@ opensuse_tumbleweed_task: ubuntu23_task: container: - # Ubuntu 23.04 EOL: January 2024 - dockerfile: ci/ubuntu-23.04/Dockerfile + # Ubuntu 23.10 EOL: July 2024 + dockerfile: ci/ubuntu-23.10/Dockerfile << : *RESOURCES_TEMPLATE << : *CI_TEMPLATE diff --git a/ci/ubuntu-23.04/Dockerfile b/ci/ubuntu-23.10/Dockerfile similarity index 97% rename from ci/ubuntu-23.04/Dockerfile rename to ci/ubuntu-23.10/Dockerfile index b468bb9d23..de278f6f87 100644 --- a/ci/ubuntu-23.04/Dockerfile +++ b/ci/ubuntu-23.10/Dockerfile @@ -1,4 +1,4 @@ -FROM ubuntu:23.04 +FROM ubuntu:23.10 ENV DEBIAN_FRONTEND="noninteractive" TZ="America/Los_Angeles" From 2ceae52bfac3c41539101f17c4d83b2b26c185c7 Mon Sep 17 00:00:00 2001 From: Christian Kreibich Date: Thu, 14 Dec 2023 15:40:47 -0800 Subject: [PATCH 12/14] CI: Move Debian variations from 11 to 12 This switches the ARM and static builds from 11 to 12. x86 and ARM now build by default, and 11 only with fullci. 10 remains as-is, because we like to torture ourselves. (cherry picked from commit 4f6c25bb91b935666b6748b95c2b6ee55c1491ad) --- .cirrus.yml | 38 +++++++++++++++++++------------------- 1 file changed, 19 insertions(+), 19 deletions(-) diff --git a/.cirrus.yml b/.cirrus.yml index 43f205115c..e6c3caae35 100644 --- a/.cirrus.yml +++ b/.cirrus.yml @@ -212,7 +212,26 @@ debian12_task: dockerfile: ci/debian-12/Dockerfile << : *RESOURCES_TEMPLATE << : *CI_TEMPLATE + +arm_debian12_task: + arm_container: + # Debian 12 (bookworm) EOL: TBD + dockerfile: ci/debian-12/Dockerfile + << : *RESOURCES_TEMPLATE + << : *CI_TEMPLATE + env: + ZEEK_CI_CONFIGURE_FLAGS: *NO_SPICY_CONFIG + +debian12_static_task: + container: + # Just use a recent/common distro to run a static compile test. + # Debian 12 (bookworm) EOL: TBD + dockerfile: ci/debian-12/Dockerfile + << : *RESOURCES_TEMPLATE + << : *CI_TEMPLATE << : *SKIP_TASK_ON_PR + env: + ZEEK_CI_CONFIGURE_FLAGS: *STATIC_CONFIG debian11_task: container: @@ -220,26 +239,7 @@ debian11_task: dockerfile: ci/debian-11/Dockerfile << : *RESOURCES_TEMPLATE << : *CI_TEMPLATE - -arm_debian11_task: - arm_container: - # Debian 11 EOL: June 2026 - dockerfile: ci/debian-11/Dockerfile - << : *RESOURCES_TEMPLATE - << : *CI_TEMPLATE - env: - ZEEK_CI_CONFIGURE_FLAGS: *NO_SPICY_CONFIG - -debian11_static_task: - container: - # Just use a recent/common distro to run a static compile test. - # Debian 11 EOL: June 2026 - dockerfile: ci/debian-11/Dockerfile - << : *RESOURCES_TEMPLATE - << : *CI_TEMPLATE << : *SKIP_TASK_ON_PR - env: - ZEEK_CI_CONFIGURE_FLAGS: *STATIC_CONFIG debian10_task: container: From 5e383ad13e79eee4855e6ec7e77f49cd5b0b3bbf Mon Sep 17 00:00:00 2001 From: Arne Welzel Date: Fri, 15 Dec 2023 15:12:19 +0100 Subject: [PATCH 13/14] ci: Remove ZEEK_CI_DISABLE_SCRIPT_PROFILING logic To my knowledge this doesn't make a huge difference anymore and locally I'm only using ASAN builds. It's not actually too slow. (cherry picked from commit 344369f169b872b8dcb569f089b02e026fe7cfc2) --- .cirrus.yml | 2 -- ci/test.sh | 16 ---------------- 2 files changed, 18 deletions(-) diff --git a/.cirrus.yml b/.cirrus.yml index e6c3caae35..54f0d56865 100644 --- a/.cirrus.yml +++ b/.cirrus.yml @@ -388,7 +388,6 @@ asan_sanitizer_task: env: CXXFLAGS: -DZEEK_DICT_DEBUG ZEEK_CI_CONFIGURE_FLAGS: *ASAN_SANITIZER_CONFIG - ZEEK_CI_DISABLE_SCRIPT_PROFILING: 1 ASAN_OPTIONS: detect_leaks=1 ubsan_sanitizer_task: @@ -403,7 +402,6 @@ ubsan_sanitizer_task: env: CXXFLAGS: -DZEEK_DICT_DEBUG ZEEK_CI_CONFIGURE_FLAGS: *UBSAN_SANITIZER_CONFIG - ZEEK_CI_DISABLE_SCRIPT_PROFILING: 1 ZEEK_TAILORED_UB_CHECKS: 1 UBSAN_OPTIONS: print_stacktrace=1 diff --git a/ci/test.sh b/ci/test.sh index b643293911..310212ab00 100755 --- a/ci/test.sh +++ b/ci/test.sh @@ -59,13 +59,6 @@ function run_btests { pushd testing/btest - # Commenting out this line in btest.cfg causes the script profiling/coverage - # to be disabled. We do this for the sanitizer build right now because of a - # fairly significant performance bug when running tests. - if [ "${ZEEK_CI_DISABLE_SCRIPT_PROFILING}" = "1" ]; then - sed -i 's/^ZEEK_PROFILER_FILE/#ZEEK_PROFILER_FILE/g' btest.cfg - fi - ${BTEST} -z ${ZEEK_CI_BTEST_RETRIES} -d -A -x btest-results.xml -j ${ZEEK_CI_BTEST_JOBS} || result=1 make coverage prep_artifacts @@ -74,15 +67,6 @@ function run_btests { } function run_external_btests { - # Commenting out this line in btest.cfg causes the script profiling/coverage - # to be disabled. We do this for the sanitizer build right now because of a - # fairly significant performance bug when running tests. - if [ "${ZEEK_CI_DISABLE_SCRIPT_PROFILING}" = "1" ]; then - pushd testing/external - sed -i 's/^ZEEK_PROFILER_FILE/#ZEEK_PROFILER_FILE/g' subdir-btest.cfg - popd - fi - local zeek_testing_pid="" local zeek_testing_pid_private="" pushd testing/external/zeek-testing From 8a5576e93e170a0f9b82ece95625c96fd8719a17 Mon Sep 17 00:00:00 2001 From: Tim Wojtulewicz Date: Fri, 5 Jan 2024 10:12:54 -0700 Subject: [PATCH 14/14] CI: Remove unused openssl30_config (cherry picked from commit 652ba502aab843574402ec53aa0a6561b21253f3) --- .cirrus.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.cirrus.yml b/.cirrus.yml index 54f0d56865..0a48ec9f48 100644 --- a/.cirrus.yml +++ b/.cirrus.yml @@ -16,7 +16,6 @@ static_config: &STATIC_CONFIG --build-type=release --disable-broker-tests --enab asan_sanitizer_config: &ASAN_SANITIZER_CONFIG --build-type=debug --disable-broker-tests --sanitizers=address --enable-fuzzers --enable-coverage --disable-spicy --ccache ubsan_sanitizer_config: &UBSAN_SANITIZER_CONFIG --build-type=debug --disable-broker-tests --sanitizers=undefined --enable-fuzzers --disable-spicy --ccache tsan_sanitizer_config: &TSAN_SANITIZER_CONFIG --build-type=debug --disable-broker-tests --sanitizers=thread --enable-fuzzers --disable-spicy --ccache -openssl30_config: &OPENSSL30_CONFIG --build-type=release --disable-broker-tests --with-openssl=/opt/openssl --prefix=$CIRRUS_WORKING_DIR/install --ccache resources_template: &RESOURCES_TEMPLATE cpu: *CPUS