Skip to content

Tag images by NUT version + document tag scheme (closes #3)#4

Merged
Nardo86 merged 1 commit into
masterfrom
feat/version-based-tags
Jul 17, 2026
Merged

Tag images by NUT version + document tag scheme (closes #3)#4
Nardo86 merged 1 commit into
masterfrom
feat/version-based-tags

Conversation

@Nardo86

@Nardo86 Nardo86 commented Jul 17, 2026

Copy link
Copy Markdown
Owner

Why

Issue #3 asked how the YYYY.MM tags map to NUT server versions. They didn't — the date tags are build stamps, and the NUT version (from Debian's nut-server package) was invisible from the tag name. This makes the version a first-class, discoverable thing.

What changed

docker-publish.yml

  • New step Resolve packaged NUT version: queries the nut-server candidate from debian:bookworm-slim (package versions are identical across arches).
  • New tags: X.Y.Z-R (e.g. 2.8.0-7, exact Debian version) and X.Y.Z (e.g. 2.8.0, upstream pointer that moves to the newest Debian revision). latest, the YYYY.MM build stamp, and the legacy *-latest aliases stay.
  • New OCI labels org.networkupstools.version / org.networkupstools.upstream, and org.opencontainers.image.version now carries the NUT version (was latest).
  • Dropped the unused type=semver patterns and the v*.*.* git-tag trigger — versioning is NUT-based now.
  • Permissions: contents: readwrite for the keepalive commit.

Keepalive — the monthly build now writes and commits NUT_VERSION. This keeps the repo active so GitHub doesn't auto-disable the schedule after 60 days of inactivity. That auto-disable already bit us: no monthly tags exist between 2025.10 and 2026.05 because the cron was disabled during that idle stretch.

NUT_VERSION — human-readable record of the packaged version (seeded to the current 2.8.0-7), refreshed by each monthly build.

README.md — new "Tags & versions" section explaining the two-axis scheme (which NUT version vs. which build) and how to inspect any tag via the OCI label or upsd -V.

Existing published tags (retagged separately, no rebuild)

docker buildx imagetools create was used to add version tags to the already-published images:

  • 2.8.0-7, 2.8.0 → current bookworm image
  • 2.7.4-13, 2.7.4 → previous bullseye line (2025.062025.10)

Note to verify

The keepalive relies on the monthly GITHUB_TOKEN commit counting as repo activity. If GitHub still disables the schedule around the 60-day mark, the fallback is a PAT-authored commit or the workflow re-enable API — but the token-commit approach is the low-friction default worth trying first.

🤖 Generated with Claude Code

Tags were date-based (YYYY.MM), which didn't reveal the NUT server
version inside — the point raised in issue #3. Now the build resolves the
packaged nut-server version from Debian bookworm and tags/labels the image
by it, while keeping date tags as immutable build stamps.

- Add version tags `X.Y.Z-R` (e.g. 2.8.0-7) and `X.Y.Z` (e.g. 2.8.0).
- Add OCI labels org.networkupstools.version / .upstream and set
  org.opencontainers.image.version to the NUT version.
- Record the built version in NUT_VERSION; the monthly commit doubles as a
  keepalive so GitHub doesn't auto-disable the cron after 60 days idle
  (which already caused the 2025.11–2026.04 gap in published tags).
- Document the two-axis tag scheme (version vs build) in the README.
- Drop unused semver git-tag triggers/patterns (versioning is NUT-based).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@Nardo86
Nardo86 merged commit def799d into master Jul 17, 2026
2 checks passed
@Nardo86
Nardo86 deleted the feat/version-based-tags branch July 17, 2026 09:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant