/usr is package manager territory, and not even writable on OSTree based
systems such as Fedora CoreOS or RHEL Edge. This has been common and
good practice in autotools for decades.
You can still override this with `make install PREFIX=...`. Use that in
the RPM spec file.
Include CSS linting by default for our CSS/SCSS files, originally
introduced in cockpit. The stylelint configuration is copied from
760a4628282e02fbcef3.
- Generalize NODE_MODULES_TEST comment to apply for both direct
`npm install` and git checkouts.
- Drop obsolete touch commands from dist tarfile build.
- Consistently use NODE_MODULES_TEST constant.
- Better sorting of .PHONY, and add missing prepare-check.
This reduces the diff to cockpit-podman.
Use the html2po and manifest2po tools that we already check out from
cockpit repo pkg/lib.
These tools switched to a new argument parser library (`argparse`) in
cockpit-project/cockpit#16271, so add it to our package.json and drop
`stdio`.
Drop our old copies.
I checked the result of building `po/starter-kit.pot` before and after
the change, and aside from the timestamp, it's identical.
Cherry-picked from cockpit-podman commit bf53f801b17ba6.
Replace the two rules for test/common and pkg/lib with a single rule
based on `git-archive`, avoiding the use of racy `FETCH_HEAD` and
side-effecting `git-checkout`. This lets us drop the `flock` call, and
introduces some logic to avoid the fetch in case we already have it.
We'll hardcode shas from here on out: it's more secure (ie:
tamperproof), and more performant (since we don't have to check the ref
if we already have the object), in addition to being easier to work with
in terms of the required git commands.
Use pkg/lib/cockpit.js as a stamp file.
This rule will make it easier to expand to more files in the future.
One drawback is that when we want to update files from the cockpit/
repository, we'll now need to do it in lock-step: using new API from
testlib will force us to adjust to PatternFly changes, for example.
Cherry-picked from cockpit-podman commit cfc05e730d6f5d.
Keep pkg/lib in the same location as it is in the cockpit repository,
and adjust the include path accordingly.
This makes the production of the .pot file somewhat more deterministic:
previously, it would either include or not include the strings from
pkg/lib depending on if it had been checked out or not. Now it never
includes them.
Cherry-picked from cockpit-podman commit a70630be2139a.
RHEL 8 has node 10, which is too old for current
jest-worker/eslint/stylelint NPM modules.
The webpack rebuild during RPM build was introduced to satisfy Fedora
packaging policy, but it's not a requirement on RHEL 8. So just disable
it there.
The GKE container only has the default 64 MiB /dev/shm, which is not
enough for Chromium. It cannot be remounted from inside the container,
and chromium's `--disable-dev-shm-usage` option does not actually work,
so run the tests with Firefox instead.
All cockpit extensions should only require the bridge, at least as long
as they are independent from any other page (which is usually the case).
We still need cockpit-system for the tests (thus keep it in
test/browser/main.fmf), but it is perfectly reasonable to look at a
particular Cockpit page via the "remote hosts" panel, cockpit-desktop,
or Cockpit Client.
This gets rid of our "release" environment with high-profile secrets,
and the cockpituous/release infra.
The upstream release uses our shared
https://github.com/cockpit-project/action-release/ action.