Skip to content

Add release selection for the GitHub-released server types - #4339

Merged
itzg merged 5 commits into
itzg:masterfrom
fewwan:pumpkin-release
Oct 18, 2026
Merged

itzg merged 5 commits into
itzg:masterfrom
fewwan:pumpkin-release

Conversation

@fewwan

@fewwan fewwan commented Oct 15, 2026 •

Copy link
Copy Markdown
Contributor

What this changes

Adds a consistent way to pick which upstream GitHub release a server type runs, via <TYPE>_RELEASE, defaulting to latest.

The actual release lookup lives in mc-image-helper (itzg/mc-image-helper#905): github download-asset gains --release-tag — when omitted it uses the latest release, otherwise it resolves /releases/tags/{tag}, so pre-releases are usable — and the command was renamed from download-latest-asset, which is retained as an alias. The image only passes --release-tag when <TYPE>_RELEASE is set to something other than latest, so latest keeps its meaning of "the latest release".

Server types covered here:

  • PUMPKIN_RELEASE
  • POSEIDON_RELEASE — also removes the placeholder TODO from start-deployPoseidon
  • NANOLIMBO_RELEASE
  • KETTING_RELEASE
  • CRUCIBLE_RELEASE / ARCLIGHT_RELEASE — moved off their direct api.github.com calls onto the shared helper, which drops the bespoke JSONPath asset matching and honours GH_TOKEN

When the variable is unset, each type keeps its existing latest behavior.

Testing

New setup-only tests pin a non-latest release for each type (pumpkin-release, poseidon-release, nanolimbo-release, ketting-release, crucible-release, arclight-release), alongside the existing latest-default tests for those types.

Depends on itzg/mc-image-helper#905.

@itzg

itzg commented Oct 15, 2026

Copy link
Copy Markdown
Owner

Thank you for adding this.

I would really prefer to enhance mc-image-helper's github command to handle non-latest versions

https://github.com/itzg/mc-image-helper/tree/main/src/main/java/me/itzg/helpers/github

If that isn't feasible for you, then I could apply your changes here and follow up later porting over that missing part of the helper.

@fewwan

fewwan commented Oct 16, 2026

Copy link
Copy Markdown
Contributor Author

Thanks @itzg. I've added the enhancement to mc-image-helper: itzg/mc-image-helper#905 adds a --release-tag option to github download-latest-asset (defaults to latest; any other value resolves that tag's release via /releases/tags/{tag}, so pre-releases work too). Once that's released I'll switch this PR over to use it and drop the direct-download workaround.

@fewwan

fewwan commented Oct 16, 2026 •

Copy link
Copy Markdown
Contributor Author

Update: I've implemented your suggested approach in itzg/mc-image-helper#905:

  • github download-asset gains a --release-tag option (defaults to latest; any other value resolves /releases/tags/{tag}, so pre-releases work too)
  • the command was renamed from download-latest-asset to download-asset, with download-latest-asset kept as an alias

Once that's released I'll switch this PR over and drop the direct-download workaround. While I was at it, I generalised the same mechanism to the other server types that ship an asset in a GitHub release, so this PR will grow to cover:

  • PUMPKIN_RELEASE
  • POSEIDON_RELEASE (this finally replaces the placeholder TODO in start-deployPoseidon)
  • NANOLIMBO_RELEASE
  • KETTING_RELEASE
  • CRUCIBLE_RELEASE / ARCLIGHT_RELEASE — switched off their direct api.github.com calls onto the shared helper, which removes the bespoke JSONPath matching and honours GH_TOKEN for rate limit handling

@fewwan fewwan changed the title Add PUMPKIN_RELEASE to select the Pumpkin version Add release selection for the GitHub-released server types Oct 16, 2026
Add a <TYPE>_RELEASE option so a specific release tag can be selected
instead of always the latest, for the server types that download an asset
from a GitHub release:

- PUMPKIN_RELEASE
- POSEIDON_RELEASE
- NANOLIMBO_RELEASE
- KETTING_RELEASE

CRUCIBLE and ARCLIGHT already had a release option, but resolved the
release with a direct api.github.com call. They now use the shared
mc-image-helper 'github download-asset' command, which resolves the
release and matches the asset. This removes the direct API calls, honors
GH_TOKEN for rate limit handling, and allows a pre-release, such as a
Crucible staging tag, to be selected.

mc-image-helper treats an omitted --release-tag as the latest release, so
the release tag is only passed when a specific release was requested. This
keeps <TYPE>_RELEASE=latest meaning the latest release.

Depends on itzg/mc-image-helper#905, which adds --release-tag, renames
download-latest-asset to download-asset, and leaves the tag unset by
default (keeping the old name as an alias). MC_HELPER_VERSION will need to
be bumped once itzg#905 is released.

@itzg itzg left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry for the ripple effect of my "latest" request in helper.

Comment thread scripts/start-deployArcLight Outdated
Comment thread scripts/start-deployCrucible Outdated
Comment thread scripts/start-deployKetting
Comment thread scripts/start-deployNanoLimbo
Comment thread scripts/start-deployPoseidon
Comment thread scripts/start-deployPumpkin
@itzg

itzg commented Oct 16, 2026

Copy link
Copy Markdown
Owner

And thanks for retrofitting the others.

@itzg

itzg commented Oct 16, 2026

Copy link
Copy Markdown
Owner

java8 build is because the feature will need to be back-ported. I just now added more info about this

https://github.com/itzg/mc-image-helper/blob/main/DEVELOPMENT.md#java-compatibility

I can take care of doing that, if you want.

@@ -0,0 +1,7 @@
mc-image-helper assert fileExists "/data/pumpkin-*-Linux"

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The java25-alpine build verification failed since it seems to include the -musl suffix

[init] Using Pumpkin server executable /data/pumpkin-X64-Linux-musl

@fewwan

fewwan commented Oct 17, 2026

Copy link
Copy Markdown
Contributor Author

Update on the java8 leg: I've opened the helper back-port per the process in DEVELOPMENT.md#java-compatibility.

Once it's merged and the next 1.51.x-java8 release is cut, this PR will need its mcHelperVersion: 1.51.4-java8 pins bumped (.github/workflows/build.yml x4 and .github/workflows/verify-pr.yml x1) so the java8 CI leg goes green. Happy to make that change here, or submit it separately, once the version is published.

@itzg

itzg commented Oct 17, 2026

Copy link
Copy Markdown
Owner

The java8 release is https://github.com/itzg/mc-image-helper/releases/tag/1.51.5-java8 and that will be great to bump the pinned versions within this PR.

fewwan and others added 2 commits October 18, 2026 22:31
1.51.5-java8 back-ports the github download-asset release tag support
(itzg/mc-image-helper#908), so the pre-Java 17 variants (java16, java11,
java8, java8-jdk) can select a specific GitHub release. This fixes the
java8 verify-pr leg, which failed with "Unmatched arguments ...
'download-asset'" against the pinned 1.51.4-java8.
@fewwan

fewwan commented Oct 18, 2026

Copy link
Copy Markdown
Contributor Author

The java8 leg is green now — thanks for the back-port release.

Bumped the pinned helper from 1.51.4-java8 to 1.51.5-java8 since that release includes the download-asset / --release-tag support (itzg/mc-image-helper#908):

  • .github/workflows/build.yml — java16, java11, java8, and java8-jdk
  • .github/workflows/verify-pr.yml — java8

All checks now pass (java8/java17/java25/java25-alpine/java25-graalvm, docs, verify).

@itzg itzg left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for all the work on this.

@itzg
itzg merged commit dbb0909 into itzg:master Oct 18, 2026
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants