mirror of
https://github.com/rsyslog/rsyslog.git
synced 2026-08-24 19:24:14 +02:00
Why: Daily packages need a small, tested feature delta while retaining each target distribution's native package definitions. Impact: Daily stable base packages require YAML support, and omazuredce is built and published as a separate installable package. Before: Native baselines determined the complete feature set, and published-package smoke tests did not verify YAML parsing or optional module ownership. After: A shared contract overlays the native Debian, RPM, openSUSE, and Alpine definitions, asserts the module artifact, and smoke-tests exact published package versions. Technical Overview: Add a strict packaging overlay, native-family package naming, artifact assertions, and installed-package YAML/module validation to every current daily-stable workflow. With the help of AI-Agents: Codex
36 lines
784 B
Bash
Executable File
36 lines
784 B
Bash
Executable File
#!/usr/bin/env bash
|
|
# Verify the package contract after installing the base and module packages.
|
|
set -euo pipefail
|
|
|
|
rsyslogd_bin="${RSYSLOGD_BIN:-rsyslogd}"
|
|
module_args=()
|
|
if [ -n "${RSYSLOG_MODULE_PATH:-}" ]; then
|
|
module_args=(-M "$RSYSLOG_MODULE_PATH")
|
|
fi
|
|
|
|
tmp_dir="$(mktemp -d)"
|
|
trap 'rm -rf "$tmp_dir"' EXIT
|
|
|
|
cat > "$tmp_dir/base.yaml" <<'EOF'
|
|
version: 2
|
|
global:
|
|
preserveFQDN: "off"
|
|
rulesets:
|
|
- name: main
|
|
script: |
|
|
action(type="omfile" file="/dev/null")
|
|
EOF
|
|
|
|
cat > "$tmp_dir/omazuredce.yaml" <<'EOF'
|
|
version: 2
|
|
modules:
|
|
- load: omazuredce
|
|
rulesets:
|
|
- name: main
|
|
script: |
|
|
action(type="omfile" file="/dev/null")
|
|
EOF
|
|
|
|
"$rsyslogd_bin" -N1 -f "$tmp_dir/base.yaml" "${module_args[@]}"
|
|
"$rsyslogd_bin" -N1 -f "$tmp_dir/omazuredce.yaml" "${module_args[@]}"
|