Name: cockpit-microshift Version: 0.2.0 Release: 1%{?dist} Summary: Cockpit UI for managing a local MicroShift instance License: Apache-2.0 # Unlike cockpit-project/starter-kit, this package always installs the # pre-built dist/ shipped in the release tarball rather than conditionally # rebuilding the JS bundle from source on distributions with nodejs-esbuild. # That path was tried and dropped: it needs the bundled npm dependencies # (react, react-dom, the PatternFly packages) available as system node # modules, which no distribution ships, and Node's ESM loader doesn't even # resolve build.js's own `import esbuild from 'esbuild'` via NODE_PATH the # way the equivalent CommonJS pattern would. Confirmed by reproducing the # exact %build command below directly on Fedora. Source0: cockpit-microshift-0.2.0.tar.xz BuildArch: noarch BuildRequires: make BuildRequires: libappstream-glib Requires: cockpit-bridge # Runtime npm packages bundled into dist/index.js. Kept as static entries # (rather than generated from an esbuild metafile, as starter-kit does) # since this project only bundles its own direct dependencies straight # from package.json -- update versions here when package.json changes. Provides: bundled(npm(@patternfly/react-core)) = 6.6.1 Provides: bundled(npm(@patternfly/react-icons)) = 6.6.1 Provides: bundled(npm(@patternfly/react-table)) = 6.6.1 Provides: bundled(npm(react)) = 18.3.1 Provides: bundled(npm(react-dom)) = 18.3.1 %description A Cockpit plugin for managing a local MicroShift instance: systemd service status/restart, apiserver and node health checks, a pod list, a generic browser for the core resource kinds (Namespaces, Deployments, Services, Routes, ...), and a log tail -- all via cockpit.spawn(), no separate backend daemon. %prep %autosetup -n cockpit-microshift-0.2.0 %build # nothing to do -- dist/ is already built, shipped in the source tarball %install %make_install PREFIX=/usr # drop source maps, they are large and just for debugging find %{buildroot}%{_datadir}/cockpit/ -name '*.map' | xargs --no-run-if-empty rm --verbose %check appstream-util validate-relax --nonet %{buildroot}%{_datadir}/metainfo/*.metainfo.xml %files %doc README.md %license LICENSE %{_datadir}/cockpit/* %{_datadir}/metainfo/* %changelog