obs-tools image: add the npm_lockfile service and Node.js 22 - #17
Merged
Conversation
Bake the repo-owned npm_lockfile OBS-style service (tools/obs-services/) into ghcr.io/percona/obs-tools together with Node.js 22 + npm, cpio and obs-service-node-modules, so percona-obs can generate package-lock.json and vendor npm dependencies for packages whose upstream ships no npm lockfile (pgAdmin 4). build-obs-image.yml now also rebuilds the image when tools/obs-services/ changes. Split out of the pgadmin-sp1 branch (PR #12): the PR check runs inside obs-tools:latest, which is only rebuilt from main, so the service must land on main before PR #12 can sync. Signed-off-by: Ricardo Dias <ricardo.dias@percona.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
PR #12 (pgAdmin 4,
pgadmin-sp1) adds packages whose_serviceruns the repo-ownednpm_lockfileservice (SP1). The PR check runs insideghcr.io/percona/obs-tools:latest, whichbuild-obs-image.ymlrebuilds only on pushes tomain— so the image cannot contain a service that only exists on the PR branch, and the PR #12 sync fails with:This PR carries only the image inputs, split out of
pgadmin-sp1, so that merging it rebuildsobs-tools:latestfrommainwith the service included.pgadmin-sp1will then be rebased on top ofmain.What
.github/docker/obs-tools/Dockerfile:cpio,obs-service-node-modules+python3-lxml, Node.js 22 + npm (NodeSource; major 22 matches thenodejs:22module stream used on UBI_9), andCOPYoftools/obs-services/npm_lockfile{,.service}into/usr/lib/obs/service/..github/workflows/build-obs-image.yml:tools/obs-services/**added to thepaths:trigger.tools/obs-services/: thenpm_lockfileservice (stdlib-only Python), its.servicedescriptor and README.tests/test_npm_lockfile.py: unit tests for the service (13, standalone — load the script by path).No packaging content changes; nothing under
root/, so no OBS sync is involved.Verification
venv/bin/python -m pytest tests/test_npm_lockfile.py→ 13 passed.docs/superpowers/specs/2026-08-26-pgadmin4-tooling-design.md§8); this PR contains those exact files.build-obs-image.ymlruns onmain(Dockerfile +tools/obs-services/**changed) and publishesobs-tools:latest; the PR pgAdmin 4 for UBI-9: SP1 node_modules tooling + SP2 local-npm-registry + SP3 Python 3.12 stack #12 check can then be re-run.