From 6f8da3ad90bc9a3712996faf44c0a68556678675 Mon Sep 17 00:00:00 2001 From: Florian Forster Date: Fri, 24 Nov 2023 15:17:56 +0100 Subject: [PATCH 1/6] Upgrade GitHub actions to latest version. --- .github/workflows/daily-jobs.yml | 4 ++-- .github/workflows/merge-jobs.yml | 2 +- .github/workflows/weekly-jobs.yml | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/daily-jobs.yml b/.github/workflows/daily-jobs.yml index 70050d7..720b6de 100644 --- a/.github/workflows/daily-jobs.yml +++ b/.github/workflows/daily-jobs.yml @@ -23,7 +23,7 @@ jobs: SLUG: "collectd/ci:${{ matrix.branch }}" steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 with: ref: ${{ matrix.branch }} - name: Build container @@ -32,7 +32,7 @@ jobs: - run: docker inspect "${SLUG}" - run: docker history "${SLUG}" - name: Log into the container registry - uses: docker/login-action@v1 + uses: docker/login-action@v3 with: username: ${{ secrets.DOCKER_USERNAME }} password: ${{ secrets.DOCKER_PASSWORD }} diff --git a/.github/workflows/merge-jobs.yml b/.github/workflows/merge-jobs.yml index 7c83809..4db6027 100644 --- a/.github/workflows/merge-jobs.yml +++ b/.github/workflows/merge-jobs.yml @@ -20,7 +20,7 @@ jobs: - run: docker history "${SLUG:?}" - run: docker images - name: Log into the container registry - uses: docker/login-action@v1 + uses: docker/login-action@v3 with: username: ${{ secrets.DOCKER_USERNAME }} password: ${{ secrets.DOCKER_PASSWORD }} diff --git a/.github/workflows/weekly-jobs.yml b/.github/workflows/weekly-jobs.yml index 4b9f383..22195db 100644 --- a/.github/workflows/weekly-jobs.yml +++ b/.github/workflows/weekly-jobs.yml @@ -39,7 +39,7 @@ jobs: SLUG: "collectd/ci:${{ matrix.branch }}" steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 with: ref: ${{ matrix.branch }} - name: Build container @@ -48,7 +48,7 @@ jobs: - run: docker inspect "${SLUG}" - run: docker history "${SLUG}" - name: Log into the container registry - uses: docker/login-action@v1 + uses: docker/login-action@v3 with: username: ${{ secrets.DOCKER_USERNAME }} password: ${{ secrets.DOCKER_PASSWORD }} From 9f542f6753a42822eabb66aa464a2e60198ede4a Mon Sep 17 00:00:00 2001 From: Florian Forster Date: Mon, 27 Nov 2023 10:44:14 +0100 Subject: [PATCH 2/6] README.md: some wording improvements. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Mention the `main` branch instead of "master". * Reflect the renaming of "sid_amd64" to "debian_unstable". * Update the example to mention debian_unstable – other releases are changing too frequently, causing the documentation to become outdated. --- README.md | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/README.md b/README.md index b19c19e..d852db3 100644 --- a/README.md +++ b/README.md @@ -4,29 +4,29 @@ Helper images for building collectd Here is a collection of manifests used to build the Docker images hosted at: -There is one branch per distribution/architecture pair which collectd is tested -against. Common bits are stored in the master branch, and merged into the -distro branches when needed. +There is one branch per distribution/version against which collectd is tested. +Common bits, most notably GitHub Actions, are stored in the main branch, and +merged into the distro branches when needed. Each Dockerfile contains a list of package names (mostly support libraries) to -install, and a list of plugins collectd *master* is expected to build based on +install, and a list of plugins collectd *main* is expected to build based on them. We want to stick to the official repositories, and only install packages found there, to ensure collectd releases integrate smoothly in these distributions. -Travis-CI takes care of building these images and pushing them to -cloud.docker.com. NB: Debian/sid and Fedora/rawhide built are triggered once -per day (as these distributions change constantly). You'll find the build logs -there: +GitHub Actions take care of building these images and pushing them to +`cloud.docker.com`. + +NOTE: Debian unstable ("Sid") and Fedora unstable ("Rawhide") are rebuilt daily +(as these distributions change frequently). The goal is to have the resulting images fit in the collectd project's CI, but -they are free to use for any other case. Only patches related to the CI will be -considered, though. +they are free to use for any other case. -Here's an example of how you could build collectd in an Ubuntu/Xenial -environment: -``` +Here's an example of how you can build collectd on Debian unstable: + +```shell git clone https://github.com/collectd/collectd -docker run -it --rm -v $PWD/collectd:/collectd -w /collectd collectd/ci:xenial_amd64 -./build.sh && ./configure && make && make check +docker run -it --rm -v $PWD/collectd:/collectd -w /collectd collectd/ci:debian_unstable +./build.sh && ./configure && make all check ``` From 63e07b31e84348cb814cbf829ca9bd982837ef39 Mon Sep 17 00:00:00 2001 From: Florian Forster Date: Wed, 6 Dec 2023 16:18:16 +0100 Subject: [PATCH 3/6] checks/check-built-plugins.sh: Accept expected plugins as arguments. The idea is to allow the `collectd-6.0` branch to overwrite this list. --- checks/check-built-plugins.sh | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/checks/check-built-plugins.sh b/checks/check-built-plugins.sh index 147050d..0862db9 100755 --- a/checks/check-built-plugins.sh +++ b/checks/check-built-plugins.sh @@ -3,9 +3,16 @@ set -e declare -A want -for p in ${SUPPORTED_PLUGIN_LIST}; do - want["${p}"]=1 -done +if [[ $# -ge 1 ]]; then + while [[ $# -ge 1 ]]; do + want["${1}"]=1 + shift + done +else + for p in ${SUPPORTED_PLUGIN_LIST}; do + want["${p}"]=1 + done +fi declare -A got for f in .libs/*.so; do From 70abe0c83973d891aa2b69cf28e0e59249107e29 Mon Sep 17 00:00:00 2001 From: Florian Forster Date: Wed, 6 Dec 2023 16:39:20 +0100 Subject: [PATCH 4/6] checks/check-built-plugins.sh: Read expected plugins from a file. --- checks/check-built-plugins.sh | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/checks/check-built-plugins.sh b/checks/check-built-plugins.sh index 0862db9..305fc02 100755 --- a/checks/check-built-plugins.sh +++ b/checks/check-built-plugins.sh @@ -4,9 +4,8 @@ set -e declare -A want if [[ $# -ge 1 ]]; then - while [[ $# -ge 1 ]]; do - want["${1}"]=1 - shift + for p in $(egrep -v '^ *($|#)' "${1}"); do + want["${p}"]=1 done else for p in ${SUPPORTED_PLUGIN_LIST}; do From c13d85946f68e20b0e5228fdae0491aa5faffa53 Mon Sep 17 00:00:00 2001 From: Florian Forster Date: Wed, 6 Dec 2023 16:45:56 +0100 Subject: [PATCH 5/6] Daily job: rename `sid_amd64` to `debian_unstable`. --- .github/workflows/daily-jobs.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/daily-jobs.yml b/.github/workflows/daily-jobs.yml index 720b6de..2dd6215 100644 --- a/.github/workflows/daily-jobs.yml +++ b/.github/workflows/daily-jobs.yml @@ -15,7 +15,7 @@ jobs: matrix: branch: - - sid_amd64 + - debian_unstable - fedora38_x86_64 - fedora_rawhide_x86_64 From bac09b5e7442e8d217eb035254c2a29473c0c623 Mon Sep 17 00:00:00 2001 From: Florian Forster Date: Thu, 21 Dec 2023 13:17:06 +0100 Subject: [PATCH 6/6] Inform the user when the `SUPPORTED_PLUGIN_LIST` environment variable is used. --- checks/check-built-plugins.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/checks/check-built-plugins.sh b/checks/check-built-plugins.sh index 305fc02..a0721b1 100755 --- a/checks/check-built-plugins.sh +++ b/checks/check-built-plugins.sh @@ -8,6 +8,7 @@ if [[ $# -ge 1 ]]; then want["${p}"]=1 done else + echo "No plugins on the command line; using SUPPORTED_PLUGIN_LIST instead." for p in ${SUPPORTED_PLUGIN_LIST}; do want["${p}"]=1 done