From 2a840e374eccc0bd5a521a476b8c566efcaef86b Mon Sep 17 00:00:00 2001 From: Aliaksandr Adziareika <8034372+alexadereyko@users.noreply.github.com> Date: Fri, 14 Aug 2026 16:35:02 +0200 Subject: [PATCH 01/15] Publish the LT streaming module stagings The stage workflow pulls the core staging matching each job, builds the modules against it and publishes them to ghcr. CPack packs the module runtime into a TGZ named by opendaq-cmake-utils, the same way core names its packages. --- .github/workflows/stage.yml | 125 ++++++++++++++++++++++++++++++++++++ CMakeLists.txt | 7 ++ CMakePresets.json | 10 +++ cmake/CMakeLists.txt | 2 +- cmake/Packing.cmake | 53 +++++++++++++++ 5 files changed, 196 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/stage.yml create mode 100644 cmake/Packing.cmake diff --git a/.github/workflows/stage.yml b/.github/workflows/stage.yml new file mode 100644 index 0000000..264254d --- /dev/null +++ b/.github/workflows/stage.yml @@ -0,0 +1,125 @@ +name: Build LT streaming module stagings + +on: + push: + branches: [main] + pull_request: + types: [opened, reopened, synchronize, ready_for_review] + workflow_dispatch: + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +env: + # the core stagings the modules build against + CORE_STAGING: ghcr.io/${{ github.repository_owner }}/test/staging/opendaq + +jobs: + resolve: + name: Resolve staging jobs + runs-on: ubuntu-latest + outputs: + include-jobs: ${{ steps.jobs.outputs.include-jobs }} + staging-pull: ${{ steps.jobs.outputs.staging-pull }} + packages: ${{ steps.jobs.outputs.packages }} + staging-push: ${{ steps.jobs.outputs.staging-push }} + steps: + - name: Resolve staging jobs + id: jobs + shell: python3 {0} + env: + OWNER: ${{ github.repository_owner }} + REF: ${{ github.ref }} + CORE: ${{ env.CORE_STAGING }} + run: | + import json, os + + # every job pulls the core staging built the same way, selected by the annotations + # that name it + JOBS = { + "windows-2022-x86_64-msvs-v143-release": {"platform": "windows", "arch": "x86_64"}, + "windows-2022-x86-msvs-v143-release": {"platform": "windows", "arch": "x86"}, + "manylinux_2_28-x86_64-ninja-gcc-release": {"platform": "manylinux_2_28", "arch": "x86_64"}, + "ubuntu-22.04-x86_64-ninja-gcc-release": {"platform": "linux", "arch": "x86_64"}, + "ubuntu-22.04-armv8-ninja-gcc-release": {"platform": "linux", "arch": "armv8"}, + "macos-26-x86_64-ninja-appleclang-release":{"platform": "macos", "arch": "x86_64"}, + "macos-26-armv8-ninja-appleclang-release": {"platform": "macos", "arch": "armv8"}, + } + + owner = os.environ["OWNER"] + ref = os.environ["REF"] + core = os.environ["CORE"] + + if ref.startswith("refs/heads/release/"): + channel = "stable" + elif ref == "refs/heads/main": + channel = "dev" + else: + channel = "test" + + resolved = { + "include-jobs": list(JOBS), + "staging-pull": [{ + "artifact": f"core-{job}", + "packages": [{ + "path": core, + "tag": "latest", + "annotations": { + "com.opendaq.custom.platform": settings["platform"], + "com.opendaq.settings.arch": settings["arch"], + }, + }], + } for job, settings in JOBS.items()], + "packages": [{ + "match-jobs": [job], + "artifacts": [{"name": f"core-{job}", "dir": "staging-deps"}], + } for job in JOBS], + "staging-push": [{ + "path": f"ghcr.io/{owner}/{channel}/staging/lt-streaming-modules", + "artifacts": ["staging-*/lt-streaming"], + "tags": ["latest"], + }], + } + + with open(os.environ["GITHUB_OUTPUT"], "a") as f: + for key, value in resolved.items(): + f.write(f"{key}={json.dumps(value)}\n") + + print(json.dumps(resolved, indent=2)) + + stage: + needs: resolve + name: LtStreamingModulesModern + permissions: + contents: read + packages: write + uses: openDAQ/openDAQ-CI/.github/workflows/stage.yml@jira/TBBAS-3439-multi-staging + with: + timeout: '[{"timeout-minutes": 180}]' + staging-pull: ${{ needs.resolve.outputs.staging-pull }} + include-jobs: ${{ needs.resolve.outputs.include-jobs }} + packages: ${{ needs.resolve.outputs.packages }} + cmake-presets: > + [ + { + "match-jobs": ["*"], + "configure-preset": "stage", + "cache-variables": + { + "CMAKE_PREFIX_PATH": "${sourceDir}/staging-deps;${sourceDir}/staging-deps/opt/opendaq" + } + }, + { + "match-jobs": ["macos-*"], + "cache-variables": {"CMAKE_OSX_DEPLOYMENT_TARGET": "10.15"} + } + ] + cpack-presets: > + [ + { + "match-jobs": ["*"], + "stagings": [{"name": "lt-streaming"}] + } + ] + staging-push: ${{ needs.resolve.outputs.staging-push }} diff --git a/CMakeLists.txt b/CMakeLists.txt index 02dcbe0..8fe683c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -7,6 +7,9 @@ set(REPO_OPTION_PREFIX DAQMODULES_LT_STREAMING) list(APPEND CMAKE_MESSAGE_CONTEXT ${REPO_NAME}) add_subdirectory(cmake) +# Names the install components of the modules: openDAQ__Runtime / _Development +set(SDK_NAME "${OPENDAQ_SDK_NAME}") + opendaq_read_file_contents("${CMAKE_CURRENT_LIST_DIR}/module_version" module_version) opendaq_get_version_major_minor_patch("${module_version}" ${REPO_OPTION_PREFIX}_VERSION) @@ -82,3 +85,7 @@ if (${REPO_OPTION_PREFIX}_ENABLE_TESTS AND ${REPO_OPTION_PREFIX}_ENABLE_CLIENT A add_subdirectory(tests) endif() +if (PROJECT_IS_TOP_LEVEL) + include(cmake/Packing.cmake) +endif() + diff --git a/CMakePresets.json b/CMakePresets.json index e492ee0..db9705a 100644 --- a/CMakePresets.json +++ b/CMakePresets.json @@ -224,6 +224,16 @@ "cacheVariables": { "DAQMODULES_LT_STREAMING_ENABLE_TESTS": "ON" } + }, + { + "name": "stage", + "hidden": true, + "cacheVariables": { + "DAQMODULES_LT_STREAMING_ENABLE_CLIENT": "ON", + "DAQMODULES_LT_STREAMING_ENABLE_SERVER": "ON", + "DAQMODULES_LT_STREAMING_ENABLE_EXAMPLE_APP": "OFF", + "DAQMODULES_LT_STREAMING_ENABLE_TESTS": "OFF" + } } ], "testPresets": [ diff --git a/cmake/CMakeLists.txt b/cmake/CMakeLists.txt index 9a35aa9..6c7fd46 100644 --- a/cmake/CMakeLists.txt +++ b/cmake/CMakeLists.txt @@ -8,7 +8,7 @@ include(FetchContent) FetchContent_Declare( opendaq-cmake-utils GIT_REPOSITORY https://github.com/openDAQ/opendaq-cmake-utils.git - GIT_TAG v1.0.1 + GIT_TAG ci/staging GIT_PROGRESS ON ) FetchContent_MakeAvailable(opendaq-cmake-utils) diff --git a/cmake/Packing.cmake b/cmake/Packing.cmake new file mode 100644 index 0000000..fc029f3 --- /dev/null +++ b/cmake/Packing.cmake @@ -0,0 +1,53 @@ +## +## CPack configuration for the LT streaming modules +## + +set(CPACK_PACKAGE_NAME ${PROJECT_NAME}) +set(CPACK_PACKAGE_VENDOR "openDAQ d.o.o.") +set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "openDAQ LT streaming client and server modules") +set(CPACK_PACKAGE_HOMEPAGE_URL "https://opendaq.io/") +set(CPACK_PACKAGE_CONTACT "info@opendaq.io") +set(CPACK_RESOURCE_FILE_LICENSE "${CMAKE_CURRENT_SOURCE_DIR}/LICENSE") + +set(CPACK_PACKAGE_VERSION_MAJOR ${PROJECT_VERSION_MAJOR}) +set(CPACK_PACKAGE_VERSION_MINOR ${PROJECT_VERSION_MINOR}) +set(CPACK_PACKAGE_VERSION_PATCH ${PROJECT_VERSION_PATCH}) + +set(CPACK_VERBATIM_VARIABLES ON) +set(CPACK_THREADS 0) + +set(CPACK_GENERATOR TGZ) +set(CPACK_COMPONENTS_GROUPING ALL_COMPONENTS_IN_ONE) +set(CPACK_ARCHIVE_COMPONENT_INSTALL ON) + +if(NOT CPACK_PACKAGE_DIRECTORY) + set(CPACK_PACKAGE_DIRECTORY "${CMAKE_SOURCE_DIR}/build/_packages") +endif() + +## +## Package filename and staging metadata +## +## Format: lt-streaming-modules-[-]----- +## Composed by opendaq-cmake-utils, the same way core names its packages. +## + +set(CPACK_OPENDAQ_META_PACKAGE_NAME "lt-streaming-modules") + +execute_process(COMMAND git -C "${CMAKE_CURRENT_SOURCE_DIR}" rev-parse --short=7 HEAD + OUTPUT_VARIABLE _PACKING_SHORT_SHA + OUTPUT_STRIP_TRAILING_WHITESPACE + ERROR_QUIET +) +if(_PACKING_SHORT_SHA) + set(CPACK_OPENDAQ_META_PACKAGE_VERSION_SUFFIX "-${_PACKING_SHORT_SHA}") +endif() + +opendaq_detect_settings() +opendaq_detect_package() +opendaq_compose_package_triplet() +opendaq_compose_package_file_name() + +# Let each cpack run name the package it produces (-D CPACK_OPENDAQ_META_PACKAGE_NAME=...). +set(CPACK_PROJECT_CONFIG_FILE "${CPACK_OPENDAQ_PROJECT_CONFIG}") + +include(CPack) From ab2ae80994f116b1ee9f020327b560edd24202c1 Mon Sep 17 00:00:00 2001 From: Aliaksandr Adziareika <8034372+alexadereyko@users.noreply.github.com> Date: Mon, 17 Aug 2026 16:21:04 +0200 Subject: [PATCH 02/15] Pack only the module runtime Without the component scope the package also carries the MSVC runtime that InstallRequiredSystemLibraries installs, which core already ships. --- CMakePresets.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/CMakePresets.json b/CMakePresets.json index db9705a..513c777 100644 --- a/CMakePresets.json +++ b/CMakePresets.json @@ -232,7 +232,8 @@ "DAQMODULES_LT_STREAMING_ENABLE_CLIENT": "ON", "DAQMODULES_LT_STREAMING_ENABLE_SERVER": "ON", "DAQMODULES_LT_STREAMING_ENABLE_EXAMPLE_APP": "OFF", - "DAQMODULES_LT_STREAMING_ENABLE_TESTS": "OFF" + "DAQMODULES_LT_STREAMING_ENABLE_TESTS": "OFF", + "CPACK_COMPONENTS_ALL": "openDAQ_ws_stream_cl_module_Runtime;openDAQ_ws_stream_srv_module_Runtime" } } ], From 6995eab56ba272d1117680ea5de58867b6e27ca2 Mon Sep 17 00:00:00 2001 From: Aliaksandr Adziareika <8034372+alexadereyko@users.noreply.github.com> Date: Mon, 17 Aug 2026 16:21:04 +0200 Subject: [PATCH 03/15] Pull the core staging opendaq_ref names The staging index of a core commit is tagged with its sha, so opendaq_ref -- already the ref this repository builds against -- is resolved to one and the pull asks for that, instead of whatever latest points at. The job list, what each job pulls and where the stagings are published are literal, so the workflow shows them. The job computes the two values that cannot be written down: the commit and the channel the branch publishes to. --- .github/workflows/stage.yml | 133 ++++++++++++++++-------------------- 1 file changed, 60 insertions(+), 73 deletions(-) diff --git a/.github/workflows/stage.yml b/.github/workflows/stage.yml index 264254d..cd0cf1b 100644 --- a/.github/workflows/stage.yml +++ b/.github/workflows/stage.yml @@ -11,82 +11,35 @@ concurrency: group: ${{ github.workflow }}-${{ github.ref }} cancel-in-progress: true -env: - # the core stagings the modules build against - CORE_STAGING: ghcr.io/${{ github.repository_owner }}/test/staging/opendaq - jobs: resolve: - name: Resolve staging jobs + name: Resolve the core commit runs-on: ubuntu-latest outputs: - include-jobs: ${{ steps.jobs.outputs.include-jobs }} - staging-pull: ${{ steps.jobs.outputs.staging-pull }} - packages: ${{ steps.jobs.outputs.packages }} - staging-push: ${{ steps.jobs.outputs.staging-push }} + core-sha: ${{ steps.core.outputs.core-sha }} + channel: ${{ steps.core.outputs.channel }} steps: - - name: Resolve staging jobs - id: jobs - shell: python3 {0} + - uses: actions/checkout@v4 + + - name: Resolve the core commit and the publish channel + id: core + shell: bash env: - OWNER: ${{ github.repository_owner }} - REF: ${{ github.ref }} - CORE: ${{ env.CORE_STAGING }} + GH_TOKEN: ${{ github.token }} run: | - import json, os + core_ref=$(cat opendaq_ref) + core_sha=$(gh api "/repos/openDAQ/openDAQ/commits/$core_ref" --jq .sha) \ + || { echo "::error::opendaq_ref names no commit of openDAQ/openDAQ: $core_ref"; exit 1; } - # every job pulls the core staging built the same way, selected by the annotations - # that name it - JOBS = { - "windows-2022-x86_64-msvs-v143-release": {"platform": "windows", "arch": "x86_64"}, - "windows-2022-x86-msvs-v143-release": {"platform": "windows", "arch": "x86"}, - "manylinux_2_28-x86_64-ninja-gcc-release": {"platform": "manylinux_2_28", "arch": "x86_64"}, - "ubuntu-22.04-x86_64-ninja-gcc-release": {"platform": "linux", "arch": "x86_64"}, - "ubuntu-22.04-armv8-ninja-gcc-release": {"platform": "linux", "arch": "armv8"}, - "macos-26-x86_64-ninja-appleclang-release":{"platform": "macos", "arch": "x86_64"}, - "macos-26-armv8-ninja-appleclang-release": {"platform": "macos", "arch": "armv8"}, - } + case "$GITHUB_REF" in + refs/heads/release/*) channel=stable ;; + refs/heads/main) channel=dev ;; + *) channel=test ;; + esac - owner = os.environ["OWNER"] - ref = os.environ["REF"] - core = os.environ["CORE"] - - if ref.startswith("refs/heads/release/"): - channel = "stable" - elif ref == "refs/heads/main": - channel = "dev" - else: - channel = "test" - - resolved = { - "include-jobs": list(JOBS), - "staging-pull": [{ - "artifact": f"core-{job}", - "packages": [{ - "path": core, - "tag": "latest", - "annotations": { - "com.opendaq.custom.platform": settings["platform"], - "com.opendaq.settings.arch": settings["arch"], - }, - }], - } for job, settings in JOBS.items()], - "packages": [{ - "match-jobs": [job], - "artifacts": [{"name": f"core-{job}", "dir": "staging-deps"}], - } for job in JOBS], - "staging-push": [{ - "path": f"ghcr.io/{owner}/{channel}/staging/lt-streaming-modules", - "artifacts": ["staging-*/lt-streaming"], - "tags": ["latest"], - }], - } - - with open(os.environ["GITHUB_OUTPUT"], "a") as f: - for key, value in resolved.items(): - f.write(f"{key}={json.dumps(value)}\n") - - print(json.dumps(resolved, indent=2)) + echo "core-sha=$core_sha" >> "$GITHUB_OUTPUT" + echo "channel=$channel" >> "$GITHUB_OUTPUT" + echo "opendaq_ref $core_ref -> $core_sha, channel $channel" stage: needs: resolve @@ -97,10 +50,37 @@ jobs: uses: openDAQ/openDAQ-CI/.github/workflows/stage.yml@jira/TBBAS-3439-multi-staging with: timeout: '[{"timeout-minutes": 180}]' - staging-pull: ${{ needs.resolve.outputs.staging-pull }} - include-jobs: ${{ needs.resolve.outputs.include-jobs }} - packages: ${{ needs.resolve.outputs.packages }} - cmake-presets: > + staging-pull: >- + [ + { "artifact": "core-windows-2022-x86_64-msvs-v143-release", "packages": [{ "path": "ghcr.io/openDAQ/test/staging/opendaq", "tag": "${{ needs.resolve.outputs.core-sha }}", "annotations": { "com.opendaq.custom.platform": "windows", "com.opendaq.settings.arch": "x86_64" } }] }, + { "artifact": "core-windows-2022-x86-msvs-v143-release", "packages": [{ "path": "ghcr.io/openDAQ/test/staging/opendaq", "tag": "${{ needs.resolve.outputs.core-sha }}", "annotations": { "com.opendaq.custom.platform": "windows", "com.opendaq.settings.arch": "x86" } }] }, + { "artifact": "core-manylinux_2_28-x86_64-ninja-gcc-release", "packages": [{ "path": "ghcr.io/openDAQ/test/staging/opendaq", "tag": "${{ needs.resolve.outputs.core-sha }}", "annotations": { "com.opendaq.custom.platform": "manylinux_2_28", "com.opendaq.settings.arch": "x86_64" } }] }, + { "artifact": "core-ubuntu-22.04-x86_64-ninja-gcc-release", "packages": [{ "path": "ghcr.io/openDAQ/test/staging/opendaq", "tag": "${{ needs.resolve.outputs.core-sha }}", "annotations": { "com.opendaq.custom.platform": "linux", "com.opendaq.settings.arch": "x86_64" } }] }, + { "artifact": "core-ubuntu-22.04-armv8-ninja-gcc-release", "packages": [{ "path": "ghcr.io/openDAQ/test/staging/opendaq", "tag": "${{ needs.resolve.outputs.core-sha }}", "annotations": { "com.opendaq.custom.platform": "linux", "com.opendaq.settings.arch": "armv8" } }] }, + { "artifact": "core-macos-26-x86_64-ninja-appleclang-release","packages": [{ "path": "ghcr.io/openDAQ/test/staging/opendaq", "tag": "${{ needs.resolve.outputs.core-sha }}", "annotations": { "com.opendaq.custom.platform": "macos", "com.opendaq.settings.arch": "x86_64" } }] }, + { "artifact": "core-macos-26-armv8-ninja-appleclang-release", "packages": [{ "path": "ghcr.io/openDAQ/test/staging/opendaq", "tag": "${{ needs.resolve.outputs.core-sha }}", "annotations": { "com.opendaq.custom.platform": "macos", "com.opendaq.settings.arch": "armv8" } }] } + ] + include-jobs: >- + [ + "windows-2022-x86_64-msvs-v143-release", + "windows-2022-x86-msvs-v143-release", + "manylinux_2_28-x86_64-ninja-gcc-release", + "ubuntu-22.04-x86_64-ninja-gcc-release", + "ubuntu-22.04-armv8-ninja-gcc-release", + "macos-26-x86_64-ninja-appleclang-release", + "macos-26-armv8-ninja-appleclang-release" + ] + packages: >- + [ + { "match-jobs": ["windows-2022-x86_64-msvs-v143-release"], "artifacts": [{ "name": "core-windows-2022-x86_64-msvs-v143-release", "dir": "staging-deps" }] }, + { "match-jobs": ["windows-2022-x86-msvs-v143-release"], "artifacts": [{ "name": "core-windows-2022-x86-msvs-v143-release", "dir": "staging-deps" }] }, + { "match-jobs": ["manylinux_2_28-x86_64-ninja-gcc-release"], "artifacts": [{ "name": "core-manylinux_2_28-x86_64-ninja-gcc-release", "dir": "staging-deps" }] }, + { "match-jobs": ["ubuntu-22.04-x86_64-ninja-gcc-release"], "artifacts": [{ "name": "core-ubuntu-22.04-x86_64-ninja-gcc-release", "dir": "staging-deps" }] }, + { "match-jobs": ["ubuntu-22.04-armv8-ninja-gcc-release"], "artifacts": [{ "name": "core-ubuntu-22.04-armv8-ninja-gcc-release", "dir": "staging-deps" }] }, + { "match-jobs": ["macos-26-x86_64-ninja-appleclang-release"],"artifacts": [{ "name": "core-macos-26-x86_64-ninja-appleclang-release", "dir": "staging-deps" }] }, + { "match-jobs": ["macos-26-armv8-ninja-appleclang-release"], "artifacts": [{ "name": "core-macos-26-armv8-ninja-appleclang-release", "dir": "staging-deps" }] } + ] + cmake-presets: >- [ { "match-jobs": ["*"], @@ -115,11 +95,18 @@ jobs: "cache-variables": {"CMAKE_OSX_DEPLOYMENT_TARGET": "10.15"} } ] - cpack-presets: > + cpack-presets: >- [ { "match-jobs": ["*"], "stagings": [{"name": "lt-streaming"}] } ] - staging-push: ${{ needs.resolve.outputs.staging-push }} + staging-push: >- + [ + { + "path": "ghcr.io/${{ github.repository_owner }}/${{ needs.resolve.outputs.channel }}/staging/lt-streaming-modules", + "artifacts": ["staging-*/lt-streaming"], + "tags": ["latest"] + } + ] From b5459960540839544f67b6086e9c05968e37cf24 Mon Sep 17 00:00:00 2001 From: Aliaksandr Adziareika <8034372+alexadereyko@users.noreply.github.com> Date: Mon, 17 Aug 2026 16:46:54 +0200 Subject: [PATCH 04/15] Pin core to a staged commit Stagings exist only from openDAQ/openDAQ#1265 on, so this is the one core commit the pull can resolve today. --- opendaq_ref | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/opendaq_ref b/opendaq_ref index 7f0493c..9f753c3 100644 --- a/opendaq_ref +++ b/opendaq_ref @@ -1 +1 @@ -1e654ad4d8ab6211c78412928b888bb1cf5d1875 \ No newline at end of file +5accba3872459c322e004e0d481439ede373a8ec From 65131cf55b71f888675710a10fb4f5b5e8c6a82c Mon Sep 17 00:00:00 2001 From: Aliaksandr Adziareika <8034372+alexadereyko@users.noreply.github.com> Date: Tue, 18 Aug 2026 15:38:26 +0200 Subject: [PATCH 05/15] Publish the stagings weekly, not on every merge A staging matrix is seven runners, and most of the merges between two runs produce nothing a consumer asks for. workflow_dispatch covers what cannot wait for the schedule. --- .github/workflows/stage.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/stage.yml b/.github/workflows/stage.yml index cd0cf1b..b5aec13 100644 --- a/.github/workflows/stage.yml +++ b/.github/workflows/stage.yml @@ -1,8 +1,8 @@ name: Build LT streaming module stagings on: - push: - branches: [main] + schedule: + - cron: '0 2 * * 1' pull_request: types: [opened, reopened, synchronize, ready_for_review] workflow_dispatch: From 803ce3c4b5d2d950de2f23c3d2edc1d35445b379 Mon Sep 17 00:00:00 2001 From: Aliaksandr Adziareika <8034372+alexadereyko@users.noreply.github.com> Date: Tue, 18 Aug 2026 15:45:31 +0200 Subject: [PATCH 06/15] Trigger on push to main again Temporary: until the workflow reaches main, workflow_dispatch is not offered, so pushing is the only way to run it outside a pull request. --- .github/workflows/stage.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/stage.yml b/.github/workflows/stage.yml index b5aec13..fa4f5c2 100644 --- a/.github/workflows/stage.yml +++ b/.github/workflows/stage.yml @@ -1,6 +1,7 @@ name: Build LT streaming module stagings on: + push: schedule: - cron: '0 2 * * 1' pull_request: From ac40446e3975e523a320556df52e3d3c139ac13d Mon Sep 17 00:00:00 2001 From: Aliaksandr Adziareika <8034372+alexadereyko@users.noreply.github.com> Date: Wed, 19 Aug 2026 16:50:28 +0200 Subject: [PATCH 07/15] Bump core to the current staging The commit the pin named was staged before the branch was rebased; this one is what core publishes now. --- opendaq_ref | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/opendaq_ref b/opendaq_ref index 9f753c3..d07ff75 100644 --- a/opendaq_ref +++ b/opendaq_ref @@ -1 +1 @@ -5accba3872459c322e004e0d481439ede373a8ec +60f8ae4d08a02a9a262c457d3e1da759e6f92bc6 From 160db68a1aeb31a2c47f1a696805fef7b73bcd16 Mon Sep 17 00:00:00 2001 From: Aliaksandr Adziareika <8034372+alexadereyko@users.noreply.github.com> Date: Wed, 19 Aug 2026 17:08:57 +0200 Subject: [PATCH 08/15] Install OpenSSL where the image lacks it The TLS channel needs OpenSSL, and the ubuntu containers, manylinux and 32-bit Windows do not ship it. Same recipe as the downstream CI: the package manager where there is one, vcpkg on Windows. --- .github/workflows/stage.yml | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/.github/workflows/stage.yml b/.github/workflows/stage.yml index fa4f5c2..f9ead07 100644 --- a/.github/workflows/stage.yml +++ b/.github/workflows/stage.yml @@ -79,7 +79,11 @@ jobs: { "match-jobs": ["ubuntu-22.04-x86_64-ninja-gcc-release"], "artifacts": [{ "name": "core-ubuntu-22.04-x86_64-ninja-gcc-release", "dir": "staging-deps" }] }, { "match-jobs": ["ubuntu-22.04-armv8-ninja-gcc-release"], "artifacts": [{ "name": "core-ubuntu-22.04-armv8-ninja-gcc-release", "dir": "staging-deps" }] }, { "match-jobs": ["macos-26-x86_64-ninja-appleclang-release"],"artifacts": [{ "name": "core-macos-26-x86_64-ninja-appleclang-release", "dir": "staging-deps" }] }, - { "match-jobs": ["macos-26-armv8-ninja-appleclang-release"], "artifacts": [{ "name": "core-macos-26-armv8-ninja-appleclang-release", "dir": "staging-deps" }] } + { "match-jobs": ["macos-26-armv8-ninja-appleclang-release"], "artifacts": [{ "name": "core-macos-26-armv8-ninja-appleclang-release", "dir": "staging-deps" }] }, + + { "match-jobs": ["ubuntu-*"], "apt-install": ["libssl-dev"] }, + { "match-jobs": ["manylinux*"], "yum-install": ["openssl-devel"] }, + { "match-jobs": ["windows-*-x86-*"], "run": "vcpkg install openssl:x86-windows; Add-Content -Path $env:GITHUB_PATH -Value C:\\vcpkg\\installed\\x86-windows\\bin -Encoding utf8" } ] cmake-presets: >- [ @@ -94,6 +98,10 @@ jobs: { "match-jobs": ["macos-*"], "cache-variables": {"CMAKE_OSX_DEPLOYMENT_TARGET": "10.15"} + }, + { + "match-jobs": ["windows-*-x86-*"], + "cache-variables": {"OPENSSL_ROOT_DIR": "C:/vcpkg/installed/x86-windows"} } ] cpack-presets: >- From aa0c5ea7593602b0e2be89ee735ab0043bb65ac8 Mon Sep 17 00:00:00 2001 From: Aliaksandr Adziareika <8034372+alexadereyko@users.noreply.github.com> Date: Wed, 19 Aug 2026 17:39:08 +0200 Subject: [PATCH 09/15] Stop staging on pull requests A pull request is checked out as its merge commit, so what it publishes is tagged with a sha that lives in no branch and cannot be pinned or cloned. --- .github/workflows/stage.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/stage.yml b/.github/workflows/stage.yml index f9ead07..5db0808 100644 --- a/.github/workflows/stage.yml +++ b/.github/workflows/stage.yml @@ -4,8 +4,6 @@ on: push: schedule: - cron: '0 2 * * 1' - pull_request: - types: [opened, reopened, synchronize, ready_for_review] workflow_dispatch: concurrency: From 005f2c9800220bb7638041d7b48e7972f0a070b6 Mon Sep 17 00:00:00 2001 From: Aliaksandr Adziareika <8034372+alexadereyko@users.noreply.github.com> Date: Wed, 19 Aug 2026 18:01:47 +0200 Subject: [PATCH 10/15] Pin core to a commit that is on a branch The staging pulled so far was published from a pull request, so its sha was a merge commit -- in the registry, but in no branch, so the source build could not check it out. --- opendaq_ref | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/opendaq_ref b/opendaq_ref index d07ff75..9c3b4d7 100644 --- a/opendaq_ref +++ b/opendaq_ref @@ -1 +1 @@ -60f8ae4d08a02a9a262c457d3e1da759e6f92bc6 +7e569c0afed4c5ca43ceca8ba396aa635cb8b4fc From bec0de35f242073f31264ac941f4eaf913cbe7e3 Mon Sep 17 00:00:00 2001 From: Aliaksandr Adziareika <8034372+alexadereyko@users.noreply.github.com> Date: Thu, 20 Aug 2026 07:43:19 +0200 Subject: [PATCH 11/15] Bump core to the current staging The pinned core carried a packaging bug that only shows when the SDK is built as a subproject, which is what the source path of this repository does. --- opendaq_ref | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/opendaq_ref b/opendaq_ref index 9c3b4d7..d50f279 100644 --- a/opendaq_ref +++ b/opendaq_ref @@ -1 +1 @@ -7e569c0afed4c5ca43ceca8ba396aa635cb8b4fc +4a6ee1d1912ca9fc68a435e3312a3b95ee1f3960 From 5dd6eb3202d3b8218d0d806c90c74bbfd226fab1 Mon Sep 17 00:00:00 2001 From: Aliaksandr Adziareika <8034372+alexadereyko@users.noreply.github.com> Date: Fri, 21 Aug 2026 11:54:57 +0200 Subject: [PATCH 12/15] Check that the pinned core staging exists opendaq_ref is what this repository builds against, and a merge that names a core without a staging breaks every build after it. The check asks the registry for that one staging, in the channel the branch the change lands on builds against. --- .github/workflows/check-core-staging.yml | 35 ++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 .github/workflows/check-core-staging.yml diff --git a/.github/workflows/check-core-staging.yml b/.github/workflows/check-core-staging.yml new file mode 100644 index 0000000..9da7025 --- /dev/null +++ b/.github/workflows/check-core-staging.yml @@ -0,0 +1,35 @@ +name: Check core staging + +on: + pull_request: + types: [opened, reopened, synchronize, ready_for_review] + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +jobs: + core-staging: + name: Core staging + runs-on: ubuntu-latest + permissions: + contents: read + packages: read + steps: + - uses: actions/checkout@v4 + + - uses: openDAQ/openDAQ-CI/.github/actions/resolve-channel@jira/TBBAS-3477-staging-check + id: channel + + - name: Read the pinned core ref + shell: bash + run: echo "CORE_REF=$(cat opendaq_ref)" >> "$GITHUB_ENV" + + - uses: openDAQ/openDAQ-CI/.github/actions/staging-check@jira/TBBAS-3477-staging-check + env: + CHANNEL: ${{ steps.channel.outputs.channel }} + with: + packages: >- + [ + { "path": "ghcr.io/openDAQ/$CHANNEL/staging/opendaq", "tag": "$CORE_REF" } + ] From 7d62b6cbec79a5190477a3043c2339042a3fd38f Mon Sep 17 00:00:00 2001 From: Aliaksandr Adziareika <8034372+alexadereyko@users.noreply.github.com> Date: Fri, 21 Aug 2026 18:03:11 +0200 Subject: [PATCH 13/15] Call the reusable this repository stages with The downstream check ran on the v2 tag while the staging build already calls the branch, so the two exercised different matrices. --- .github/workflows/ci-downstream.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-downstream.yml b/.github/workflows/ci-downstream.yml index 34f45b2..27523e2 100644 --- a/.github/workflows/ci-downstream.yml +++ b/.github/workflows/ci-downstream.yml @@ -12,7 +12,7 @@ on: jobs: call-opendaq-reusable: name: LT Streaming Modern - uses: openDAQ/openDAQ-CI/.github/workflows/reusable.yml@v2 + uses: openDAQ/openDAQ-CI/.github/workflows/reusable.yml@jira/TBBAS-3439-multi-staging with: opendaq-ref: ${{ github.event.inputs.opendaq-ref || '' }} include-jobs: > From 6d58560acfaeabf201d66f21ce46d45225444a98 Mon Sep 17 00:00:00 2001 From: Aliaksandr Adziareika <8034372+alexadereyko@users.noreply.github.com> Date: Mon, 24 Aug 2026 13:44:20 +0200 Subject: [PATCH 14/15] Resolve the channel with the shared action The rule is the same in every repository, and the staging build had its own copy of it next to the gate's. Reading the pinned ref is all that is left here, and it is a line. --- .github/workflows/stage.yml | 40 +++++++++++++------------------------ 1 file changed, 14 insertions(+), 26 deletions(-) diff --git a/.github/workflows/stage.yml b/.github/workflows/stage.yml index 5db0808..e4ef342 100644 --- a/.github/workflows/stage.yml +++ b/.github/workflows/stage.yml @@ -15,30 +15,18 @@ jobs: name: Resolve the core commit runs-on: ubuntu-latest outputs: - core-sha: ${{ steps.core.outputs.core-sha }} - channel: ${{ steps.core.outputs.channel }} + core-ref: ${{ steps.core.outputs.ref }} + channel: ${{ steps.channel.outputs.channel }} steps: - uses: actions/checkout@v4 - - name: Resolve the core commit and the publish channel + - uses: openDAQ/openDAQ-CI/.github/actions/resolve-channel@jira/TBBAS-3477-staging-check + id: channel + + - name: Read the pinned core ref id: core shell: bash - env: - GH_TOKEN: ${{ github.token }} - run: | - core_ref=$(cat opendaq_ref) - core_sha=$(gh api "/repos/openDAQ/openDAQ/commits/$core_ref" --jq .sha) \ - || { echo "::error::opendaq_ref names no commit of openDAQ/openDAQ: $core_ref"; exit 1; } - - case "$GITHUB_REF" in - refs/heads/release/*) channel=stable ;; - refs/heads/main) channel=dev ;; - *) channel=test ;; - esac - - echo "core-sha=$core_sha" >> "$GITHUB_OUTPUT" - echo "channel=$channel" >> "$GITHUB_OUTPUT" - echo "opendaq_ref $core_ref -> $core_sha, channel $channel" + run: echo "ref=$(cat opendaq_ref)" >> "$GITHUB_OUTPUT" stage: needs: resolve @@ -51,13 +39,13 @@ jobs: timeout: '[{"timeout-minutes": 180}]' staging-pull: >- [ - { "artifact": "core-windows-2022-x86_64-msvs-v143-release", "packages": [{ "path": "ghcr.io/openDAQ/test/staging/opendaq", "tag": "${{ needs.resolve.outputs.core-sha }}", "annotations": { "com.opendaq.custom.platform": "windows", "com.opendaq.settings.arch": "x86_64" } }] }, - { "artifact": "core-windows-2022-x86-msvs-v143-release", "packages": [{ "path": "ghcr.io/openDAQ/test/staging/opendaq", "tag": "${{ needs.resolve.outputs.core-sha }}", "annotations": { "com.opendaq.custom.platform": "windows", "com.opendaq.settings.arch": "x86" } }] }, - { "artifact": "core-manylinux_2_28-x86_64-ninja-gcc-release", "packages": [{ "path": "ghcr.io/openDAQ/test/staging/opendaq", "tag": "${{ needs.resolve.outputs.core-sha }}", "annotations": { "com.opendaq.custom.platform": "manylinux_2_28", "com.opendaq.settings.arch": "x86_64" } }] }, - { "artifact": "core-ubuntu-22.04-x86_64-ninja-gcc-release", "packages": [{ "path": "ghcr.io/openDAQ/test/staging/opendaq", "tag": "${{ needs.resolve.outputs.core-sha }}", "annotations": { "com.opendaq.custom.platform": "linux", "com.opendaq.settings.arch": "x86_64" } }] }, - { "artifact": "core-ubuntu-22.04-armv8-ninja-gcc-release", "packages": [{ "path": "ghcr.io/openDAQ/test/staging/opendaq", "tag": "${{ needs.resolve.outputs.core-sha }}", "annotations": { "com.opendaq.custom.platform": "linux", "com.opendaq.settings.arch": "armv8" } }] }, - { "artifact": "core-macos-26-x86_64-ninja-appleclang-release","packages": [{ "path": "ghcr.io/openDAQ/test/staging/opendaq", "tag": "${{ needs.resolve.outputs.core-sha }}", "annotations": { "com.opendaq.custom.platform": "macos", "com.opendaq.settings.arch": "x86_64" } }] }, - { "artifact": "core-macos-26-armv8-ninja-appleclang-release", "packages": [{ "path": "ghcr.io/openDAQ/test/staging/opendaq", "tag": "${{ needs.resolve.outputs.core-sha }}", "annotations": { "com.opendaq.custom.platform": "macos", "com.opendaq.settings.arch": "armv8" } }] } + { "artifact": "core-windows-2022-x86_64-msvs-v143-release", "packages": [{ "path": "ghcr.io/openDAQ/test/staging/opendaq", "tag": "${{ needs.resolve.outputs.core-ref }}", "annotations": { "com.opendaq.custom.platform": "windows", "com.opendaq.settings.arch": "x86_64" } }] }, + { "artifact": "core-windows-2022-x86-msvs-v143-release", "packages": [{ "path": "ghcr.io/openDAQ/test/staging/opendaq", "tag": "${{ needs.resolve.outputs.core-ref }}", "annotations": { "com.opendaq.custom.platform": "windows", "com.opendaq.settings.arch": "x86" } }] }, + { "artifact": "core-manylinux_2_28-x86_64-ninja-gcc-release", "packages": [{ "path": "ghcr.io/openDAQ/test/staging/opendaq", "tag": "${{ needs.resolve.outputs.core-ref }}", "annotations": { "com.opendaq.custom.platform": "manylinux_2_28", "com.opendaq.settings.arch": "x86_64" } }] }, + { "artifact": "core-ubuntu-22.04-x86_64-ninja-gcc-release", "packages": [{ "path": "ghcr.io/openDAQ/test/staging/opendaq", "tag": "${{ needs.resolve.outputs.core-ref }}", "annotations": { "com.opendaq.custom.platform": "linux", "com.opendaq.settings.arch": "x86_64" } }] }, + { "artifact": "core-ubuntu-22.04-armv8-ninja-gcc-release", "packages": [{ "path": "ghcr.io/openDAQ/test/staging/opendaq", "tag": "${{ needs.resolve.outputs.core-ref }}", "annotations": { "com.opendaq.custom.platform": "linux", "com.opendaq.settings.arch": "armv8" } }] }, + { "artifact": "core-macos-26-x86_64-ninja-appleclang-release","packages": [{ "path": "ghcr.io/openDAQ/test/staging/opendaq", "tag": "${{ needs.resolve.outputs.core-ref }}", "annotations": { "com.opendaq.custom.platform": "macos", "com.opendaq.settings.arch": "x86_64" } }] }, + { "artifact": "core-macos-26-armv8-ninja-appleclang-release", "packages": [{ "path": "ghcr.io/openDAQ/test/staging/opendaq", "tag": "${{ needs.resolve.outputs.core-ref }}", "annotations": { "com.opendaq.custom.platform": "macos", "com.opendaq.settings.arch": "armv8" } }] } ] include-jobs: >- [ From dc39671240cf689dd8ee6313940f1230e4ca0e6a Mon Sep 17 00:00:00 2001 From: Aliaksandr Adziareika <8034372+alexadereyko@users.noreply.github.com> Date: Mon, 24 Aug 2026 14:45:08 +0200 Subject: [PATCH 15/15] Bump core to the current staging --- opendaq_ref | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/opendaq_ref b/opendaq_ref index d50f279..0d7a81b 100644 --- a/opendaq_ref +++ b/opendaq_ref @@ -1 +1 @@ -4a6ee1d1912ca9fc68a435e3312a3b95ee1f3960 +64ab85c594f0ad5fef169c84ae24bda251540f38