Skip to content

Commit 1f595a7

Browse files
authored
Merge pull request #10 from whamcloud/sagar-gharte/EHT-1293
[EHT-1293] Updated workflow to build RPMs through e8 el9 containers
2 parents b1b100a + 8b64470 commit 1f595a7

File tree

1 file changed

+29
-12
lines changed

1 file changed

+29
-12
lines changed

.github/workflows/whamcloud-release.yml

Lines changed: 29 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -217,20 +217,37 @@ jobs:
217217
repository: whamCloud/victorialogs-rpm
218218
path: victorialogs-rpm
219219

220-
- name: Install RPM build tools
220+
- name: Build EL8 RPMs using Rocky Linux 8 container
221221
run: |
222-
if ! command -v rpmbuild &> /dev/null; then
223-
echo "Installing RPM build tools..."
224-
sudo dnf install -y rpm-build rpmdevtools
225-
else
226-
echo "RPM build tools already installed"
227-
fi
228-
229-
- name: Build RPMs for EL8 and EL9
230-
working-directory: victorialogs-rpm
222+
echo "Building EL8 RPMs for version ${{ github.event.inputs.version }}..."
223+
docker run --rm \
224+
-v $(pwd)/victorialogs-rpm:/build \
225+
-v $(pwd)/VictoriaLogs/bin:/binaries \
226+
-w /build \
227+
rockylinux:8 \
228+
bash -c "
229+
set -e
230+
echo 'Installing RPM build tools...'
231+
dnf install -y rpm-build systemd-rpm-macros rpmdevtools
232+
echo 'Building EL8 RPMs...'
233+
make rpm VERSION=${{ github.event.inputs.version }}
234+
"
235+
236+
- name: Build EL9 RPMs using Rocky Linux 9 container
231237
run: |
232-
echo "Building RPMs for version ${{ github.event.inputs.version }}..."
233-
make rpm VERSION=${{ github.event.inputs.version }}
238+
echo "Building EL9 RPMs for version ${{ github.event.inputs.version }}..."
239+
docker run --rm \
240+
-v $(pwd)/victorialogs-rpm:/build \
241+
-v $(pwd)/VictoriaLogs/bin:/binaries \
242+
-w /build \
243+
rockylinux:9 \
244+
bash -c "
245+
set -e
246+
echo 'Installing RPM build tools...'
247+
dnf install -y rpm-build systemd-rpm-macros rpmdevtools
248+
echo 'Building EL9 RPMs...'
249+
make rpm VERSION=${{ github.event.inputs.version }}
250+
"
234251
235252
- name: List built RPMs
236253
working-directory: victorialogs-rpm

0 commit comments

Comments
 (0)