From e69926e261425602673c1033e86b36e1d87757264439e1d26c7f3105f84c11e3 Mon Sep 17 00:00:00 2001 From: Adam Majer Date: Fri, 10 Jun 2022 11:54:30 +0000 Subject: [PATCH] - new version 271 https://cockpit-project.org/blog/cockpit-271.html - cockpit-redhatfont.diff: not needed, dropped - 0001-selinux-allow-login-to-read-motd-file.patch, hide-docs.patch, hide-pcp.patch remove-pwscore.patch: refreshed OBS-URL: https://build.opensuse.org/package/show/systemsmanagement:cockpit/cockpit?expand=0&rev=88 --- ...elinux-allow-login-to-read-motd-file.patch | 14 +- README.packaging | 6 +- _service | 2 +- cockpit-251.3.obscpio | 3 - cockpit-271.obscpio | 3 + cockpit-redhatfont.diff | 19 - cockpit.changes | 9 + cockpit.obsinfo | 7 +- cockpit.spec | 181 +- hide-docs.patch | 78 +- hide-pcp.patch | 54 +- node_modules.obscpio | 4 +- node_modules.spec.inc | 1565 +- package-lock.json | 16842 +--------------- remove-pwscore.patch | 33 +- 15 files changed, 1398 insertions(+), 17422 deletions(-) delete mode 100644 cockpit-251.3.obscpio create mode 100644 cockpit-271.obscpio delete mode 100644 cockpit-redhatfont.diff diff --git a/0001-selinux-allow-login-to-read-motd-file.patch b/0001-selinux-allow-login-to-read-motd-file.patch index 51ad349..cc4e59e 100644 --- a/0001-selinux-allow-login-to-read-motd-file.patch +++ b/0001-selinux-allow-login-to-read-motd-file.patch @@ -4,13 +4,13 @@ Date: Fri Aug 6 15:11:23 2021 +0200 selinux: allow login to read motd file -diff --git a/selinux/cockpit.te b/selinux/cockpit.te -index 73242aaa1..72db3c1dc 100644 ---- a/selinux/cockpit.te -+++ b/selinux/cockpit.te -@@ -181,3 +181,11 @@ optional_policy(` - optional_policy(` - unconfined_domtrans(cockpit_session_t) +Index: cockpit/selinux/cockpit.te +=================================================================== +--- cockpit.orig/selinux/cockpit.te ++++ cockpit/selinux/cockpit.te +@@ -191,3 +191,11 @@ optional_policy(` + ') + cockpit_read_pid_files(local_login_t) ') + +# login may read motd file through pam diff --git a/README.packaging b/README.packaging index d35e71e..8fe557d 100644 --- a/README.packaging +++ b/README.packaging @@ -37,4 +37,8 @@ Sending fixes upstream: if you have any changes that should go upstream, create a new, clean branch and cherry pick *one* commit into it. Upstream wants pull -requests with only one commit +requests with only one commit + +NOTE: ONLY the .spec file should be in the git. + +IDEA: maybe other things should be removed from the git tree then? diff --git a/_service b/_service index 3e6947a..f804a83 100644 --- a/_service +++ b/_service @@ -3,7 +3,7 @@ @PARENT_TAG@ http://github.com/cockpit-project/cockpit.git git - 251.3 + 271 disable diff --git a/cockpit-251.3.obscpio b/cockpit-251.3.obscpio deleted file mode 100644 index 712cf3d..0000000 --- a/cockpit-251.3.obscpio +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:0488426c4d973a890162ad7004e138fa7a1140461f462b08bfbc755a46e69983 -size 18712589 diff --git a/cockpit-271.obscpio b/cockpit-271.obscpio new file mode 100644 index 0000000..7831c4d --- /dev/null +++ b/cockpit-271.obscpio @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5e14c15d555f34e0a4a315904a8f920d0f2033aa6dc3db638b6dec425555e3b2 +size 19679757 diff --git a/cockpit-redhatfont.diff b/cockpit-redhatfont.diff deleted file mode 100644 index 02bbc00..0000000 --- a/cockpit-redhatfont.diff +++ /dev/null @@ -1,19 +0,0 @@ -commit 95906d35cd2096ef97ccf46008f977c741e4708f -Author: Ludwig Nussel -Date: Fri Jan 22 16:32:30 2021 +0100 - - Rebuildable - -diff --git a/package.json b/package.json -index eab8c9542..56f32ce1b 100644 ---- a/package.json -+++ b/package.json -@@ -7,7 +7,7 @@ - "@patternfly/react-core": "4.147.0", - "@patternfly/react-styles": "4.11.8", - "@patternfly/react-table": "4.29.37", -- "@redhat/redhat-font": "git+https://github.com/RedHatOfficial/RedHatFont.git#2.2.0", -+ "@redhat/redhat-font": "2.2.0", - "bootstrap": "3.4.1", - "bootstrap-datepicker": "1.9.0", - "bootstrap-select": "1.13.18", diff --git a/cockpit.changes b/cockpit.changes index bf50200..8eb2a4f 100644 --- a/cockpit.changes +++ b/cockpit.changes @@ -1,3 +1,12 @@ +------------------------------------------------------------------- +Fri Jun 10 08:22:31 UTC 2022 - Adam Majer + +- new version 271 + https://cockpit-project.org/blog/cockpit-271.html +- cockpit-redhatfont.diff: not needed, dropped +- 0001-selinux-allow-login-to-read-motd-file.patch, hide-docs.patch, + hide-pcp.patch remove-pwscore.patch: refreshed + ------------------------------------------------------------------- Fri Mar 18 14:28:24 UTC 2022 - Jacek Tomasiak diff --git a/cockpit.obsinfo b/cockpit.obsinfo index fa3516b..f36839b 100644 --- a/cockpit.obsinfo +++ b/cockpit.obsinfo @@ -1,5 +1,4 @@ name: cockpit -version: 251.3 -mtime: 1638884630 -commit: 673b84201719fcb02adb8a0688400b93d58f608a - +version: 271 +mtime: 1654679280 +commit: d2d8bc30bc5279b2acc3628616cfb9c4e18c7edd diff --git a/cockpit.spec b/cockpit.spec index f561ecc..7bb82ea 100644 --- a/cockpit.spec +++ b/cockpit.spec @@ -24,10 +24,6 @@ # # Check first cockpit-devel@lists.fedorahosted.org # -# Globals that may be defined elsewhere -# * Version 122 -# * wip 1 -# # earliest base that the subpackages work on; the instances of this get computed/updated # by tools/gen-spec-dependencies during "make dist", but keep a hardcoded fallback @@ -54,7 +50,7 @@ Summary: Web Console for Linux servers License: LGPL-2.1-or-later URL: https://cockpit-project.org/ -Version: 251.3 +Version: 271 Release: 0 Source0: cockpit-%{version}.tar Source1: cockpit.pam @@ -63,7 +59,6 @@ Source99: README.packaging Source98: package-lock.json Source97: node_modules.spec.inc %include %{_sourcedir}/node_modules.spec.inc -Patch0: cockpit-redhatfont.diff Patch1: 0001-selinux-allow-login-to-read-motd-file.patch Patch2: hide-docs.patch Patch3: suse-microos-branding.patch @@ -75,7 +70,9 @@ Patch101: hide-pcp.patch # and cockpit-appstream (building optional packages like cockpit-{pcp}) # This split does not apply to EPEL/COPR. # In Fedora ELN/RHEL 9+ there is just one source package, which ships rpms in both BaseOS and AppStream -%if 0%{?rhel} == 8 && 0%{?epel} == 0 +# We also provide an override mechanism if you want to build all packages. +%define build_all 0 +%if 0%{?rhel} == 8 && 0%{?epel} == 0 && !%{build_all} %if "%{name}" == "cockpit" %define build_basic 1 @@ -90,11 +87,12 @@ Patch101: hide-pcp.patch %define build_optional 1 %endif -# Ship custom SELinux policy only in Fedora and RHEL-9 onward +# Ship custom SELinux policy (but not for cockpit-appstream) %if 0%{?rhel} >= 9 || 0%{?fedora} || 0%{?suse_version} +%if "%{name}" == "cockpit" %define selinuxtype targeted -%define with_selinux 1 -%define selinux_policy_version %(rpm --quiet -q selinux-policy && rpm -q --queryformat "%{V}-%{R}" selinux-policy || echo 1) +%define selinux_configure_arg --enable-selinux-policy=%{selinuxtype} +%endif %endif BuildRequires: gcc @@ -106,7 +104,13 @@ BuildRequires: pam-devel BuildRequires: autoconf automake BuildRequires: make BuildRequires: /usr/bin/python3 +%if 0%{?rhel} && 0%{?rhel} <= 8 +# RHEL 8's gettext does not yet have metainfo.its BuildRequires: gettext >= 0.19.7 +BuildRequires: libappstream-glib-devel +%else +BuildRequires: gettext >= 0.21 +%endif %if 0%{?build_basic} BuildRequires: libssh-devel >= 0.8.5 %endif @@ -143,11 +147,9 @@ BuildRequires: gdb # For documentation BuildRequires: xmlto -%if 0%{?with_selinux} BuildRequires: selinux-policy BuildRequires: selinux-policy-%{selinuxtype} BuildRequires: selinux-policy-devel -%endif # for rebuilding nodejs bits BuildRequires: npm @@ -163,7 +165,7 @@ Requires: cockpit-system # Optional components Recommends: (cockpit-storaged if udisks2) -Recommends: cockpit-packagekit +Recommends: (cockpit-packagekit if dnf) Suggests: cockpit-pcp %if 0%{?rhel} == 0 @@ -171,20 +173,11 @@ Recommends: (cockpit-networkmanager if NetworkManager) Suggests: cockpit-selinux %endif %if 0%{?rhel} && 0%{?centos} == 0 -Recommends: subscription-manager-cockpit +Requires: subscription-manager-cockpit %endif %prep -%setup -q -n cockpit-%{version} -%patch0 -p1 -%patch1 -p1 -%patch2 -p1 -%patch3 -p1 - -%if 0%{?sle_version} -%patch100 -p1 -%patch101 -p1 -%endif +%autosetup -p1 -n cockpit-%{version} cp %SOURCE1 tools/cockpit.pam # @@ -196,14 +189,13 @@ touch node_modules/.stamp exec 2>&1 PKG_NAME="Cockpit" -echo %version > .tarball +echo "m4_define(VERSION_NUMBER, %version)" > version.m4 autoreconf -fvi -I tools # %configure \ - --disable-silent-rules \ + %{?selinux_configure_arg} \ --with-cockpit-user=cockpit-ws \ --with-cockpit-ws-instance-user=cockpit-wsinstance \ - --with-selinux-config-type=etc_t \ %if 0%{?suse_version} --docdir=%_defaultdocdir/%{name} \ %endif @@ -212,27 +204,10 @@ autoreconf -fvi -I tools --disable-ssh \ %endif -make -j4 %{?extra_flags} all - -%if 0%{?with_selinux} - make -f /usr/share/selinux/devel/Makefile cockpit.pp - bzip2 -9 cockpit.pp -%endif +%make_build %check -# HACK: Fedora koji builders are very slow, unreliable, and inaccessible for debugging; https://github.com/cockpit-project/cockpit/issues/13909 -%if 0%{?fedora} >= 0 -%ifarch s390x -%define testsuite_fail || true -%endif -%endif -# HACK: RHEL i686 builders hang after running all tests; not a supported architecture, so don't bother -%if 0%{?rhel} >= 8 -%ifarch i686 -%define testsuite_skip # -%endif -%endif -%{?testsuite_skip} make -j4 check || { ls -l /dev/std* ; [ -e ./test-suite.log ] && cat ./test-suite.log ; false; } %{?testsuite_fail} +make -j$(nproc) check %install # In obs we get write error: stdout @@ -243,21 +218,22 @@ install -p -m 644 tools/cockpit.pam $RPM_BUILD_ROOT%{_sysconfdir}/pam.d/cockpit rm -f %{buildroot}/%{_libdir}/cockpit/*.so install -D -p -m 644 AUTHORS COPYING README.md %{buildroot}%{_docdir}/cockpit/ -%if 0%{?with_selinux} - install -D -m 644 %{name}.pp.bz2 %{buildroot}%{_datadir}/selinux/packages/%{selinuxtype}/%{name}.pp.bz2 - install -D -m 644 -t %{buildroot}%{_mandir}/man8 selinux/%{name}_session_selinux.8cockpit - install -D -m 644 -t %{buildroot}%{_mandir}/man8 selinux/%{name}_ws_selinux.8cockpit - # create this directory in the build root so that %ghost sees the desired mode - install -d -m 700 %{buildroot}%{_sharedstatedir}/selinux/%{selinuxtype}/active/modules/200/%{name} -%endif - # only ship deprecated PatternFly API for stable releases -%if 0%{?fedora} <= 33 || 0%{?rhel} <= 8 - ln -s cockpit.css.gz %{buildroot}/%{_datadir}/cockpit/base1/patternfly.css.gz +%if 0%{?rhel} == 8 + if [ -f %{buildroot}/%{_datadir}/cockpit/base1/cockpit.css.gz ]; then + ln -s cockpit.css.gz %{buildroot}/%{_datadir}/cockpit/base1/patternfly.css.gz + elif [ -f %{buildroot}/%{_datadir}/cockpit/base1/cockpit.css ]; then + ln -s cockpit.css %{buildroot}/%{_datadir}/cockpit/base1/patternfly.css + else + echo >&2 Neither cockpit.css.gz nor cockpit.css exists. + exit 1 + fi %endif # Build the package lists for resource packages -echo '%dir %{_datadir}/cockpit/base1' > base.list +# cockpit-bridge is the basic dependency for all cockpit-* packages, so centrally own the page directory +echo '%dir %{_datadir}/cockpit' > base.list +echo '%dir %{_datadir}/cockpit/base1' >> base.list echo '%dir %{_datadir}/cockpit/base1/fonts' >> base.list find %{buildroot}%{_datadir}/cockpit/base1 -type f -o -type l >> base.list echo '%{_sysconfdir}/cockpit/machines.d' >> base.list @@ -266,10 +242,10 @@ echo '%dir %{_datadir}/cockpit/ssh' >> base.list find %{buildroot}%{_datadir}/cockpit/ssh -type f >> base.list echo '%{_libexecdir}/cockpit-ssh' >> base.list -echo '%dir %{_datadir}/cockpit/pcp' >> pcp.list +echo '%dir %{_datadir}/cockpit/pcp' > pcp.list find %{buildroot}%{_datadir}/cockpit/pcp -type f >> pcp.list -echo '%dir %{_datadir}/cockpit/tuned' >> system.list +echo '%dir %{_datadir}/cockpit/tuned' > system.list find %{buildroot}%{_datadir}/cockpit/tuned -type f >> system.list echo '%dir %{_datadir}/cockpit/shell' >> system.list @@ -284,7 +260,7 @@ find %{buildroot}%{_datadir}/cockpit/users -type f >> system.list echo '%dir %{_datadir}/cockpit/metrics' >> system.list find %{buildroot}%{_datadir}/cockpit/metrics -type f >> system.list -echo '%dir %{_datadir}/cockpit/kdump' >> kdump.list +echo '%dir %{_datadir}/cockpit/kdump' > kdump.list find %{buildroot}%{_datadir}/cockpit/kdump -type f >> kdump.list echo '%dir %{_datadir}/cockpit/sosreport' > sosreport.list @@ -296,7 +272,7 @@ find %{buildroot}%{_datadir}/cockpit/storaged -type f >> storaged.list echo '%dir %{_datadir}/cockpit/networkmanager' > networkmanager.list find %{buildroot}%{_datadir}/cockpit/networkmanager -type f >> networkmanager.list -echo '%dir %{_datadir}/cockpit/packagekit' >> packagekit.list +echo '%dir %{_datadir}/cockpit/packagekit' > packagekit.list find %{buildroot}%{_datadir}/cockpit/packagekit -type f >> packagekit.list echo '%dir %{_datadir}/cockpit/apps' >> packagekit.list @@ -318,17 +294,17 @@ for pkg in base1 branding motd kdump networkmanager selinux shell sosreport ssh rm -r %{buildroot}/%{_datadir}/cockpit/$pkg rm -f %{buildroot}/%{_datadir}/metainfo/org.cockpit-project.cockpit-${pkg}.metainfo.xml done -for data in doc locale man pixmaps polkit-1; do +for data in doc man pixmaps polkit-1; do rm -r %{buildroot}/%{_datadir}/$data done for lib in systemd tmpfiles.d; do rm -r %{buildroot}/%{_prefix}/%{__lib}/$lib done -for libexec in cockpit-askpass cockpit-session cockpit-ws cockpit-tls cockpit-wsinstance-factory cockpit-desktop cockpit-certificate-helper cockpit-certificate-ensure; do +for libexec in cockpit-askpass cockpit-session cockpit-ws cockpit-tls cockpit-wsinstance-factory cockpit-client cockpit-client.ui cockpit-desktop cockpit-certificate-helper cockpit-certificate-ensure; do rm %{buildroot}/%{_libexecdir}/$libexec done rm -r %{buildroot}/%{_libdir}/security %{buildroot}/%{_sysconfdir}/pam.d %{buildroot}/%{_sysconfdir}/motd.d %{buildroot}/%{_sysconfdir}/issue.d -rm %{buildroot}/usr/bin/cockpit-bridge %{buildroot}/usr/sbin/remotectl +rm %{buildroot}/usr/bin/cockpit-bridge rm -f %{buildroot}%{_libexecdir}/cockpit-ssh rm -f %{buildroot}%{_datadir}/metainfo/cockpit.appdata.xml %endif @@ -385,10 +361,6 @@ rm -f %{buildroot}%{_datadir}/pixmaps/cockpit-sosreport.png mkdir -p %{buildroot}%{_datadir}/cockpit/devel cp -a pkg/lib %{buildroot}%{_datadir}/cockpit/devel -%if 0%{?build_basic} -%find_lang cockpit -%endif - # ------------------------------------------------------------------------------- # Basic Sub-packages @@ -405,7 +377,6 @@ troubleshooting, interactive command-line sessions, and more. %{_docdir}/cockpit/AUTHORS %{_docdir}/cockpit/COPYING %{_docdir}/cockpit/README.md -%dir %{_datadir}/cockpit %{_datadir}/metainfo/cockpit.appdata.xml %{_datadir}/pixmaps/cockpit.png %doc %{_mandir}/man1/cockpit.1.gz @@ -467,26 +438,22 @@ Provides: cockpit-tuned = %{version}-%{release} Provides: cockpit-users = %{version}-%{release} Obsoletes: cockpit-dashboard < %{version}-%{release} %if 0%{?rhel} -Provides: cockpit-networkmanager = %{version}-%{release} Requires: NetworkManager >= 1.6 -Provides: cockpit-kdump = %{version}-%{release} Requires: kexec-tools -Recommends: (sudo or polkit) +Requires: sos +Requires: sudo Recommends: PackageKit -Recommends: NetworkManager-team Recommends: setroubleshoot-server >= 3.3.3 +Suggests: NetworkManager-team +Provides: cockpit-kdump = %{version}-%{release} +Provides: cockpit-networkmanager = %{version}-%{release} Provides: cockpit-selinux = %{version}-%{release} Provides: cockpit-sosreport = %{version}-%{release} -Requires: sos %endif -%if 0%{?fedora} >= 29 -# 0.7.0 (actually) supports task cancellation. -# 0.7.1 fixes tasks never announcing completion. -Recommends: (reportd >= 0.7.1 if abrt) +%if 0%{?fedora} +Recommends: (reportd if abrt) %endif # NPM modules which are also available as packages -Provides: bundled(js-jquery) = 3.5.1 -Provides: bundled(xstatic-bootstrap-datepicker-common) = 1.9.0 Provides: bundled(xstatic-patternfly-common) = 3.59.5 %description system @@ -500,10 +467,8 @@ Summary: Cockpit Web Service Requires: glib-networking Requires: openssl Requires: glib2 >= 2.50.0 -%if 0%{?with_selinux} -Requires: (selinux-policy >= %{selinux_policy_version} if selinux-policy-%{selinuxtype}) +Requires: (selinux-policy >= %{_selinux_policy_version} if selinux-policy-%{selinuxtype}) Requires(post): (policycoreutils if selinux-policy-%{selinuxtype}) -%endif Conflicts: firewalld < 0.6.0-1 Recommends: sscg >= 2.3 Recommends: system-logos @@ -513,6 +478,11 @@ Requires(pre): permissions Requires: distribution-logos Requires: wallpaper-branding %endif +# for cockpit-desktop +Suggests: python3 + +# prevent hard python3 dependency for cockpit-desktop, it falls back to other browsers +%global __requires_exclude_from ^%{_libexecdir}/cockpit-client$ %description ws The Cockpit Web Service listens on the network, and authenticates users. @@ -520,12 +490,11 @@ The Cockpit Web Service listens on the network, and authenticates users. If sssd-dbus is installed, you can enable client certificate/smart card authentication via sssd/FreeIPA. -%files ws -f cockpit.lang -f static.list +%files ws -f static.list %doc %{_mandir}/man1/cockpit-desktop.1.gz %doc %{_mandir}/man5/cockpit.conf.5.gz %doc %{_mandir}/man8/cockpit-ws.8.gz %doc %{_mandir}/man8/cockpit-tls.8.gz -%doc %{_mandir}/man8/remotectl.8.gz %doc %{_mandir}/man8/pam_ssh_add.8.gz %dir %{_sysconfdir}/cockpit %config(noreplace) %{_sysconfdir}/cockpit/ws-certs.d @@ -545,32 +514,28 @@ authentication via sssd/FreeIPA. %{_unitdir}/cockpit.socket %{_unitdir}/cockpit-wsinstance-http.socket %{_unitdir}/cockpit-wsinstance-http.service -%{_unitdir}/cockpit-wsinstance-http-redirect.socket -%{_unitdir}/cockpit-wsinstance-http-redirect.service %{_unitdir}/cockpit-wsinstance-https-factory.socket %{_unitdir}/cockpit-wsinstance-https-factory@.service %{_unitdir}/cockpit-wsinstance-https@.socket %{_unitdir}/cockpit-wsinstance-https@.service %{_unitdir}/system-cockpithttps.slice %{_prefix}/%{__lib}/tmpfiles.d/cockpit-tempfiles.conf -%{_sbindir}/remotectl %{pamdir}/pam_ssh_add.so %{pamdir}/pam_cockpit_cert.so %{_libexecdir}/cockpit-ws %{_libexecdir}/cockpit-wsinstance-factory %{_libexecdir}/cockpit-tls +%{_libexecdir}/cockpit-client +%{_libexecdir}/cockpit-client.ui %{_libexecdir}/cockpit-desktop %{_libexecdir}/cockpit-certificate-ensure %{_libexecdir}/cockpit-certificate-helper %{?suse_version:%verify(not mode) }%attr(4750, root, cockpit-wsinstance) %{_libexecdir}/cockpit-session %{_datadir}/cockpit/branding - -%if 0%{?with_selinux} - %{_datadir}/selinux/packages/%{selinuxtype}/%{name}.pp.bz2 - %{_mandir}/man8/%{name}_session_selinux.8cockpit.* - %{_mandir}/man8/%{name}_ws_selinux.8cockpit.* - %ghost %{_sharedstatedir}/selinux/%{selinuxtype}/active/modules/200/%{name} -%endif +%{_datadir}/selinux/packages/%{selinuxtype}/%{name}.pp.bz2 +%{_mandir}/man8/%{name}_session_selinux.8cockpit.* +%{_mandir}/man8/%{name}_ws_selinux.8cockpit.* +%ghost %{_sharedstatedir}/selinux/%{selinuxtype}/active/modules/200/%{name} %pre ws getent group cockpit-ws >/dev/null || groupadd -r cockpit-ws @@ -578,25 +543,21 @@ getent passwd cockpit-ws >/dev/null || useradd -r -g cockpit-ws -d /nonexisting getent group cockpit-wsinstance >/dev/null || groupadd -r cockpit-wsinstance getent passwd cockpit-wsinstance >/dev/null || useradd -r -g cockpit-wsinstance -d /nonexisting -s /sbin/nologin -c "User for cockpit-ws instances" cockpit-wsinstance -%if 0%{?with_selinux} if %{_sbindir}/selinuxenabled 2>/dev/null; then %selinux_relabel_pre -s %{selinuxtype} fi -%endif %post ws -%if 0%{?with_selinux} -if %{_sbindir}/selinuxenabled 2>/dev/null; then +if [ -x %{_sbindir}/selinuxenabled ]; then %selinux_modules_install -s %{selinuxtype} %{_datadir}/selinux/packages/%{selinuxtype}/%{name}.pp.bz2 %selinux_relabel_post -s %{selinuxtype} fi -%endif # set up dynamic motd/issue symlinks on first-time install; don't bring them back on upgrades if admin removed them if [ "$1" = 1 ]; then mkdir -p /etc/motd.d /etc/issue.d - ln -s /run/cockpit/motd /etc/motd.d/cockpit - ln -s /run/cockpit/motd /etc/issue.d/cockpit.issue + ln -s ../../run/cockpit/motd /etc/motd.d/cockpit + ln -s ../../run/cockpit/motd /etc/issue.d/cockpit.issue fi # switch old self-signed cert group from cockpit-wsintance to cockpit-ws on upgrade if [ "$1" = 2 ]; then @@ -624,12 +585,10 @@ fi %systemd_preun cockpit.socket cockpit.service %postun ws -%if 0%{?with_selinux} -if %{_sbindir}/selinuxenabled 2>/dev/null; then +if [ -x %{_sbindir}/selinuxenabled ]; then %selinux_modules_uninstall -s %{selinuxtype} %{name} %selinux_relabel_post -s %{selinuxtype} fi -%endif %systemd_postun_with_restart cockpit.socket cockpit.service %if 0%{?suse_version} @@ -644,8 +603,8 @@ fi %package kdump Summary: Cockpit user interface for kernel crash dumping -Requires: cockpit-bridge >= 122 -Requires: cockpit-shell >= 122 +Requires: cockpit-bridge >= 130 +Requires: cockpit-shell >= 130 Requires: kexec-tools BuildArch: noarch @@ -723,10 +682,10 @@ Dummy package from building optional packages only; never install or publish me. %package -n cockpit-storaged Summary: Cockpit user interface for storage, using udisks -Requires: cockpit-shell >= 186 -Requires: udisks2 >= 2.6 -Recommends: udisks2-lvm2 >= 2.6 -Recommends: udisks2-iscsi >= 2.6 +Requires: cockpit-shell >= 266 +Requires: udisks2 >= 2.9 +Recommends: udisks2-lvm2 >= 2.9 +Recommends: udisks2-iscsi >= 2.9 Recommends: device-mapper-multipath Recommends: clevis-luks Requires: %{__python3} diff --git a/hide-docs.patch b/hide-docs.patch index 41d0cef..afc5d78 100644 --- a/hide-docs.patch +++ b/hide-docs.patch @@ -13,10 +13,10 @@ Subject: [PATCH] Hide links pointing to RHEL docs (bsc#1197003) pkg/users/manifest.json | 2 +- 7 files changed, 9 insertions(+), 9 deletions(-) -diff --git a/pkg/kdump/manifest.json b/pkg/kdump/manifest.json -index 01e5320e83f..116eb96dbdc 100644 ---- a/pkg/kdump/manifest.json -+++ b/pkg/kdump/manifest.json +Index: cockpit/pkg/kdump/manifest.json +=================================================================== +--- cockpit.orig/pkg/kdump/manifest.json ++++ cockpit/pkg/kdump/manifest.json @@ -6,7 +6,7 @@ "tools": { "index": { @@ -26,10 +26,10 @@ index 01e5320e83f..116eb96dbdc 100644 { "label": "Configuring kdump", "url": "https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/8/html/managing_systems_using_the_rhel_8_web_console/configuring-kdump-in-the-web-console_system-management-using-the-rhel-8-web-console" -diff --git a/pkg/networkmanager/manifest.json b/pkg/networkmanager/manifest.json -index 3e295e9f186..8c7eef6e3b8 100644 ---- a/pkg/networkmanager/manifest.json -+++ b/pkg/networkmanager/manifest.json +Index: cockpit/pkg/networkmanager/manifest.json +=================================================================== +--- cockpit.orig/pkg/networkmanager/manifest.json ++++ cockpit/pkg/networkmanager/manifest.json @@ -8,7 +8,7 @@ "index": { "label": "Networking", @@ -39,10 +39,10 @@ index 3e295e9f186..8c7eef6e3b8 100644 { "label": "Managing networking bonds", "url": "https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/8/html/managing_systems_using_the_rhel_8_web_console/configuring-network-bonds-using-the-web-console_system-management-using-the-rhel-8-web-console" -diff --git a/pkg/packagekit/manifest.json b/pkg/packagekit/manifest.json -index e538b4d7044..2204ae26198 100644 ---- a/pkg/packagekit/manifest.json -+++ b/pkg/packagekit/manifest.json +Index: cockpit/pkg/packagekit/manifest.json +=================================================================== +--- cockpit.orig/pkg/packagekit/manifest.json ++++ cockpit/pkg/packagekit/manifest.json @@ -8,7 +8,7 @@ "tools": { "index": { @@ -52,23 +52,10 @@ index e538b4d7044..2204ae26198 100644 { "label": "Managing software updates", "url": "https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/8/html/managing_systems_using_the_rhel_8_web_console/managing-software-updates-in-the-web-console_system-management-using-the-rhel-8-web-console" -diff --git a/pkg/shell/indexes.js b/pkg/shell/indexes.js -index adc3c165533..19d912e9bd2 100644 ---- a/pkg/shell/indexes.js -+++ b/pkg/shell/indexes.js -@@ -413,7 +413,7 @@ function MachinesIndex(index_options, machines, loader, mdialogs) { - if (os_release.DOCUMENTATION_URL) - create_item(cockpit.format(_("$0 documentation"), os_release.NAME), os_release.DOCUMENTATION_URL); - -- create_item(_("Web Console"), "https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/8/html/managing_systems_using_the_rhel_8_web_console/index"); -+ // create_item(_("Web Console"), "https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/8/html/managing_systems_using_the_rhel_8_web_console/index"); - - docs.forEach(e => create_item(_(e.label), e.url)); - -diff --git a/pkg/storaged/manifest.json b/pkg/storaged/manifest.json -index a554051798d..ef3c205222a 100644 ---- a/pkg/storaged/manifest.json -+++ b/pkg/storaged/manifest.json +Index: cockpit/pkg/storaged/manifest.json +=================================================================== +--- cockpit.orig/pkg/storaged/manifest.json ++++ cockpit/pkg/storaged/manifest.json @@ -8,7 +8,7 @@ "index": { "label": "Storage", @@ -78,10 +65,10 @@ index a554051798d..ef3c205222a 100644 { "label": "Managing partitions", "url": "https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/8/html/managing_systems_using_the_rhel_8_web_console/managing-partitions-using-the-web-console_system-management-using-the-rhel-8-web-console" -diff --git a/pkg/systemd/manifest.json b/pkg/systemd/manifest.json -index 0c768360e79..a6e8a9cc17f 100644 ---- a/pkg/systemd/manifest.json -+++ b/pkg/systemd/manifest.json +Index: cockpit/pkg/systemd/manifest.json +=================================================================== +--- cockpit.orig/pkg/systemd/manifest.json ++++ cockpit/pkg/systemd/manifest.json @@ -9,7 +9,7 @@ "index": { "label": "Overview", @@ -109,10 +96,10 @@ index 0c768360e79..a6e8a9cc17f 100644 { "label": "Reviewing logs", "url": "https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/8/html/managing_systems_using_the_rhel_8_web_console/reviewing-logs_system-management-using-the-rhel-8-web-console" -diff --git a/pkg/users/manifest.json b/pkg/users/manifest.json -index bfb5336770a..ccc408dec19 100644 ---- a/pkg/users/manifest.json -+++ b/pkg/users/manifest.json +Index: cockpit/pkg/users/manifest.json +=================================================================== +--- cockpit.orig/pkg/users/manifest.json ++++ cockpit/pkg/users/manifest.json @@ -7,7 +7,7 @@ "index": { "label": "Accounts", @@ -122,3 +109,20 @@ index bfb5336770a..ccc408dec19 100644 { "label": "Managing user accounts", "url": "https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/8/html/managing_systems_using_the_rhel_8_web_console/managing-user-accounts-in-the-web-console_system-management-using-the-rhel-8-web-console" +Index: cockpit/pkg/shell/topnav.jsx +=================================================================== +--- cockpit.orig/pkg/shell/topnav.jsx ++++ cockpit/pkg/shell/topnav.jsx +@@ -121,9 +121,9 @@ export class TopNav extends React.Compon + {cockpit.format(_("$0 documentation"), this.state.osRelease.NAME)} + ); + +- docItems.push(}> +- {_("Web Console")} +- ); ++ // docItems.push(}> ++ // {_("Web Console")} ++ // ); + + if (docs.length > 0) + docItems.push(); diff --git a/hide-pcp.patch b/hide-pcp.patch index db64f5a..7e1bd92 100644 --- a/hide-pcp.patch +++ b/hide-pcp.patch @@ -1,35 +1,21 @@ -diff --git a/pkg/metrics/metrics.jsx b/pkg/metrics/metrics.jsx -index 188aad7..a04b094 100644 ---- a/pkg/metrics/metrics.jsx -+++ b/pkg/metrics/metrics.jsx -@@ -995,6 +995,7 @@ const PCPConfig = ({ buttonVariant, firewalldRequest, needsLogout, setNeedsLogou - return ( - <> -