Repository navigation
feat(release): attach the .deb and .rpm nobody could obtain (#138) - #420
Merged
Merged
Conversation
nfpm.yaml has worked for several releases and ci.yml's packaging job builds
both formats on every PR, installs the deb, runs the postinstall scriptlet
and loads the modulefile under Lmod. release.yml had zero references to
package-linux, nfpm, .deb or .rpm, so every published release is ten assets:
five tarballs and five checksums.
$ gh release view v0.13.0 --json assets --jq '[.assets[].name] | length'
10
Same for v0.12.0 and v0.11.0. A package CI proves installable and no user
can obtain is scripts/preremove.sh before #207 -- working code with nothing
invoking it. The structural cause is #198's: make package-linux was
exercised only by a job that cannot publish, so nothing compared what CI
builds against what a release attaches.
A package-linux job now builds amd64 and arm64 packages, and publish waits
on it -- without that, a packaging failure publishes the release anyway and
a release page that looks finished is harder to notice than one that failed.
The job reads the version back out of a built package with `dpkg-deb
--field`, closing the gap nfpm.yaml's own comment names: the tag was checked
against the version constant and the constant against nfpm.yaml, and nothing
checked either against what nfpm wrote. apt-get install --only-upgrade and
dnf update decide whether to act by comparing versions, so a package
declaring a version it does not contain is an upgrade that silently does not
happen.
That read-back's first draft was wrong and running the target rather than
reasoning about the filename caught it: nfpm writes the release suffix into
both the name and the field (objectfs_0.13.0-1_amd64.deb, Version 0.13.0-1,
because nfpm.yaml pins release: '1'), so the bare version would have failed
the first release it was added to protect.
internal/config/release_packages_test.go couples the two workflows the way
release_platforms_test.go does for #198. Two of its checks initially
survived mutation, for the reason this project has now hit three times: a
strings.Contains over a whole file is satisfied by prose about the thing.
Deleting the `run: make package-linux` step passed because the comment above
the job explains what that target builds; removing the .deb and .rpm upload
paths passed because a comment and the summary step name them. Full-line
comments are now stripped and the upload assertion is scoped to one named
step, after which all eight mutations are caught -- including a deb-only
deletion hiding behind the rpm, and a renamed step, which the helpers
t.Fatalf on rather than passing for the wrong reason.
This is part (a) of #138. Parts (b) install.sh and (c) the apt/yum
repository setup are deliberately absent; (c) has no host, since
objectfs.io and packages.objectfs.io are both registrar parking pages that
do not complete a TLS handshake.
This was referenced Aug 9, 2026
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.
Part (a) of #138. Parts (b) and (c) are not in this PR — see the bottom.
The packages were built and never shipped
nfpm.yamlhas worked for several releases.ci.yml'spackagingjob builds both formats on every PR, installs the deb, runs the postinstall scriptlet, and loads the installed modulefile under Lmod. Andrelease.ymlcontained zero references topackage-linux,nfpm,.debor.rpm, so every published release is exactly ten assets — five tarballs and five checksums:Same for v0.12.0 and v0.11.0. A package CI proves installable and no user can obtain is
scripts/preremove.shbefore #207: working code with nothing invoking it.The structural cause is the one #198 had.
make package-linuxwas exercised only by a job that cannot publish anything, so nothing anywhere compared what CI builds against what a release attaches, and the two drifted in the direction that is invisible from a green tree.What this does
A
package-linuxjob betweenbuildanddocker-build-push, building both formats for amd64 and arm64, andpublishnow waits on it. The waiting matters more than it looks: without it a packaging failure publishes the release anyway, missing the packages, and a release page that looks finished is harder to notice than one that failed.The job also reads the version back out of a built package with `dpkg-deb --field`, which closes the gap
nfpm.yaml's own comment names — the tag was checked against the version constant, and the constant againstnfpm.yaml, and nothing checked either against what nfpm actually wrote. That is not cosmetic: `apt-get install --only-upgrade` and `dnf update` decide whether to act by comparing versions, so a package declaring a version it does not contain is an upgrade that silently does not happen.The read-back's first draft was wrong, and running
make package-linuxrather than reasoning about the filename is what caught it. nfpm writes the release suffix into both the name and the field —objectfs_0.13.0-1_amd64.deb,Version: 0.13.0-1, becausenfpm.yamlpinsrelease: '1'— so the version without the-1would have failed the first release it was added to protect.The gate
internal/config/release_packages_test.gocouples the two workflows the wayrelease_platforms_test.godoes for #198: a package formatci.ymlbuilds is onerelease.ymlships.Two of its checks initially survived mutation, for a reason this project has now hit three times: a `strings.Contains` over a whole file is satisfied by prose about the thing. Deleting the `run: make package-linux` step still passed, because the comment above the job explains what that target builds. Removing the
.deband.rpmupload paths still passed, because a comment and the summary step both name them.Full-line comments are now stripped and the upload assertion is scoped to one named step. All eight mutations are caught:
R2b and R2c are the ones worth noting: a deb-only deletion hiding behind the rpm, and a renamed step — which the
jobStep/needsListhelperst.Fatalfon rather than passing for the wrong reason.Verification
objectfs_0.13.0-1_amd64.deb,objectfs_0.13.0-1_arm64.deb,objectfs-0.13.0-1.x86_64.rpm,objectfs-0.13.0-1.aarch64.rpm0.13.0-1, confirmed in adebian:12containergo test -race ./...— cleanlinux/amd64 golang:1.26-alpinecontainergo build,gofmt -l .,go vet,golangci-lint run— 0 issuesrelease.ymlparses: 5 jobs,publishneeds all fourNot in this PR
#138 also specifies an install script and apt/yum repositories. Those are parts (b) and (c), and (c) has no host:
objectfs.ioandpackages.objectfs.ioboth resolve to Porkbun parking IPs and neither completes a TLS handshake. That needs a hosting decision (stand uppackages.objectfs.io, use Cloudsmith/Fury/a Pages apt-yum repo/COPR/OBS, or skip repositories), not code. Measurements and a recommended split are on #138.Closes nothing — #138 stays open for (b) and (c).