build: Move to a webpack module

Cockpit recently changed to an ESM build system [1]. Bump
COCKPIT_REPO_COMMIT to that and follow suit.

This does not work with old node.js 10 any more which is still the
default in RHEL 8. Install the newer version 16 instead.

[1] https://github.com/cockpit-project/cockpit/pull/18366
This commit is contained in:
Martin Pitt 2023-02-17 19:27:02 +01:00 committed by Katerina Koukiou
parent 1f4e0fac24
commit 4990d6a103
4 changed files with 31 additions and 23 deletions

View file

@ -19,6 +19,11 @@ dnf update -y pam || true
# we don't need the H.264 codec, and it is sometimes not available (rhbz#2005760)
dnf install --disablerepo=fedora-cisco-openh264 -y --setopt=install_weak_deps=False firefox
# nodejs 10 is too old for current Cockpit test API
if grep -q platform:el8 /etc/os-release; then
dnf module switch-to -y nodejs:16
fi
# create user account for logging in
if ! id admin 2>/dev/null; then
useradd -c Administrator -G wheel admin