Fix RFC 3339 vs RFC 3164 mixup for message format #245
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: systemd-netlogd CI | |
| on: | |
| push: | |
| branches: [ "main" ] | |
| pull_request: | |
| branches: [ "main" ] | |
| workflow_dispatch: | |
| jobs: | |
| build-ubuntu: | |
| name: Build and Test on Ubuntu | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Update package index | |
| run: sudo apt-get update | |
| - name: Install build dependencies | |
| run: | | |
| sudo apt-get install -y \ | |
| python3-sphinx \ | |
| ninja-build \ | |
| meson \ | |
| libsystemd-dev \ | |
| clang \ | |
| gperf \ | |
| libcap-dev \ | |
| build-essential \ | |
| libcmocka-dev \ | |
| libssl-dev | |
| - name: Build project | |
| run: | | |
| meson setup build | |
| meson compile -C build | |
| - name: Run tests | |
| run: meson test -C build -v | |
| - name: Install | |
| run: sudo meson install -C build | |
| - name: Create systemd-journal-netlog user | |
| run: sudo useradd -r -d / -s /usr/sbin/nologin -g systemd-journal systemd-journal-netlog || true | |
| - name: Start systemd-netlogd | |
| run: | | |
| sudo systemctl daemon-reload | |
| sudo systemctl start systemd-netlogd | |
| - name: Show service status | |
| run: sudo systemctl status systemd-netlogd | |
| build-rpm: | |
| name: Build RPM (${{ matrix.os }}) | |
| runs-on: ubuntu-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| os: [fedora:latest, fedora:41, rockylinux:9] | |
| container: | |
| image: ${{ matrix.os }} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install RPM build dependencies (Fedora) | |
| if: startsWith(matrix.os, 'fedora') | |
| run: | | |
| dnf install -y \ | |
| rpm-build \ | |
| rpmdevtools \ | |
| meson \ | |
| ninja-build \ | |
| gcc \ | |
| systemd-devel \ | |
| libcap-devel \ | |
| gperf \ | |
| openssl-devel \ | |
| libcmocka-devel \ | |
| python3-sphinx \ | |
| git | |
| - name: Install RPM build dependencies (Rocky/RHEL) | |
| if: startsWith(matrix.os, 'rockylinux') | |
| run: | | |
| dnf install -y epel-release | |
| dnf install -y \ | |
| rpm-build \ | |
| rpmdevtools \ | |
| meson \ | |
| ninja-build \ | |
| gcc \ | |
| systemd-devel \ | |
| libcap-devel \ | |
| gperf \ | |
| openssl-devel \ | |
| libcmocka-devel \ | |
| python3-sphinx \ | |
| git | |
| - name: Set up RPM build tree | |
| run: rpmdev-setuptree | |
| - name: Create source tarball | |
| run: | | |
| VERSION=$(grep "version:" meson.build | head -1 | sed "s/.*'\(.*\)'.*/\1/") | |
| echo "Building version $VERSION" | |
| git archive --format=tar.gz --prefix=systemd-netlogd-$VERSION/ -o ~/rpmbuild/SOURCES/systemd-netlogd-$VERSION.tar.gz HEAD | |
| - name: Copy spec file | |
| run: cp systemd-netlogd.spec ~/rpmbuild/SPECS/ | |
| - name: Build RPMs | |
| run: rpmbuild -ba ~/rpmbuild/SPECS/systemd-netlogd.spec | |
| - name: Test install RPM | |
| run: | | |
| dnf install -y ~/rpmbuild/RPMS/*/systemd-netlogd-*.rpm | |
| rpm -qi systemd-netlogd | |
| systemctl status systemd-netlogd || true | |
| - name: Upload RPM artifacts | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: rpms-${{ matrix.os }} | |
| path: | | |
| ~/rpmbuild/RPMS/*/*.rpm | |
| ~/rpmbuild/SRPMS/*.rpm | |
| retention-days: 30 | |
| build-deb: | |
| name: Build DEB (${{ matrix.os }}) | |
| runs-on: ubuntu-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| os: [ubuntu:24.04, ubuntu:22.04, debian:12] | |
| container: | |
| image: ${{ matrix.os }} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install build dependencies | |
| env: | |
| DEBIAN_FRONTEND: noninteractive | |
| run: | | |
| apt-get update | |
| apt-get install -y \ | |
| build-essential \ | |
| debhelper \ | |
| meson \ | |
| ninja-build \ | |
| pkg-config \ | |
| libsystemd-dev \ | |
| libcap-dev \ | |
| gperf \ | |
| libssl-dev \ | |
| libcmocka-dev \ | |
| python3-sphinx \ | |
| fakeroot \ | |
| devscripts | |
| - name: Build DEB package | |
| run: dpkg-buildpackage -us -uc -b | |
| - name: Test install DEB | |
| run: | | |
| dpkg -i ../systemd-netlogd_*.deb || apt-get install -f -y | |
| dpkg -s systemd-netlogd | |
| systemctl status systemd-netlogd || true | |
| - name: Upload DEB artifacts | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: debs-${{ matrix.os }} | |
| path: ../*.deb | |
| retention-days: 30 | |
| build-archlinux: | |
| name: Build on Arch Linux | |
| runs-on: ubuntu-latest | |
| container: | |
| image: archlinux:latest | |
| steps: | |
| - name: Install base-devel and dependencies | |
| run: | | |
| pacman -Syu --noconfirm | |
| pacman -S --noconfirm \ | |
| base-devel \ | |
| meson \ | |
| gperf \ | |
| libcap \ | |
| openssl \ | |
| systemd-libs \ | |
| python-sphinx \ | |
| cmocka \ | |
| git | |
| - uses: actions/checkout@v4 | |
| - name: Build | |
| run: | | |
| meson setup build \ | |
| --prefix=/usr/lib/systemd \ | |
| --sysconfdir=/etc/systemd | |
| meson compile -C build | |
| - name: Run tests | |
| run: meson test -C build -v | |
| - name: Install | |
| run: meson install -C build --destdir "$PWD/pkg" |