88 type : string
99
1010jobs :
11- rpm-build :
11+ setup :
1212 runs-on : ubuntu-latest
1313 container : ${{ inputs.os }}
14+ outputs :
15+ artifact-name : ${{ steps.set-artifact-name.outputs.artifactName }}
1416 steps :
1517 - name : Install git
1618 run : dnf install -y git
@@ -23,30 +25,72 @@ jobs:
2325 dpdk : true
2426 nfb : true
2527 nemea : true
26-
2728 - name : Mark github workspace as safe
2829 run : git config --system --add safe.directory $PWD
2930 - name : Create build directory
3031 run : mkdir build
31- - name : Configure CMake to make rpm
32+ - name : Set artifact name
33+ id : set-artifact-name
3234 run : |
35+ OS=${{ inputs.os }}
36+ echo "artifactName=$(echo ${OS/:/}-rpm)" >> $GITHUB_OUTPUT
37+
38+ build-rpm :
39+ needs : setup
40+ runs-on : ubuntu-latest
41+ container : ${{ inputs.os }}
42+ steps :
43+ - uses : actions/checkout@v4
44+ - name : Build rpm
45+ run : |
46+ mkdir -p build
3347 cd build
34- cmake3 .. -DCMAKE_BUILD_TYPE=Release -DENABLE_INPUT_PCAP=ON -DENABLE_INPUT_DPDK=ON -DENABLE_INPUT_NFB=ON -DENABLE_PROCESS_EXPERIMENTAL=ON
48+ cmake3 .. -DCMAKE_BUILD_TYPE=Release \
49+ -DENABLE_INPUT_PCAP=ON \
50+ -DENABLE_INPUT_DPDK=ON \
51+ -DENABLE_INPUT_NFB=ON \
52+ -DENABLE_PROCESS_EXPERIMENTAL=ON
3553 make -j $(nproc) rpm
36- - name : make rpm-msec
37- run : make -j $(nproc) rpm-msec
38- - name : make rpm-nemea
54+ - uses : actions/upload-artifact@v4
55+ with :
56+ name : ${{ needs.setup.outputs.artifact-name }}
57+ path : build/pkg/rpm/rpmbuild/RPMS/x86_64
58+ retention-days : 7
59+
60+ build-rpm-msec :
61+ needs : setup
62+ runs-on : ubuntu-latest
63+ container : ${{ inputs.os }}
64+ steps :
65+ - uses : actions/checkout@v4
66+ - name : Build rpm-msec
3967 run : |
68+ mkdir -p build
4069 cd build
41- cmake3 .. -DCMAKE_BUILD_TYPE=Release -DENABLE_OUTPUT_UNIREC=ON -DENABLE_PROCESS_EXPERIMENTAL=ON
42- make -j $(nproc) rpm-nemea
43- - name : extract artifact name
70+ cmake3 .. -DCMAKE_BUILD_TYPE=Release
71+ make -j $(nproc) rpm-msec
72+ - uses : actions/upload-artifact@v4
73+ with :
74+ name : ${{ needs.setup.outputs.artifact-name }}
75+ path : build/pkg/rpm/rpmbuild/RPMS/x86_64
76+ retention-days : 7
77+
78+ build-rpm-nemea :
79+ needs : setup
80+ runs-on : ubuntu-latest
81+ container : ${{ inputs.os }}
82+ steps :
83+ - uses : actions/checkout@v4
84+ - name : Build rpm-nemea
4485 run : |
45- OS=${{ inputs.os }}
46- echo "artifactName=$(echo ${OS/:/}-rpm)" >> $GITHUB_ENV
47- - name : upload RPM artifact
48- uses : actions/upload-artifact@v4
86+ mkdir -p build
87+ cd build
88+ cmake3 .. -DCMAKE_BUILD_TYPE=Release \
89+ -DENABLE_OUTPUT_UNIREC=ON \
90+ -DENABLE_PROCESS_EXPERIMENTAL=ON
91+ make -j $(nproc) rpm-nemea
92+ - uses : actions/upload-artifact@v4
4993 with :
50- name : ${{ env.artifactName }}
51- path : ./ build/pkg/rpm/rpmbuild/RPMS/x86_64
52- retention-days : 1
94+ name : ${{ needs.setup.outputs.artifact-name }}
95+ path : build/pkg/rpm/rpmbuild/RPMS/x86_64
96+ retention-days : 7
0 commit comments