Skip to content

Add support for ubuntu 26.04 - #361

Merged
ronivay merged 1 commit into
ronivay:masterfrom
batinicaz:feature/ubuntu-26-04-support
Aug 4, 2026
Merged

Add support for ubuntu 26.04#361
ronivay merged 1 commit into
ronivay:masterfrom
batinicaz:feature/ubuntu-26-04-support

Conversation

@batinicaz

Copy link
Copy Markdown
Contributor

Appreciate that 26.04 only dropped a few days ago, but I rushed to upgrade, realised XO wouldn't run and then had to fix up!

Given the fix was so trivial as it is the same code path as Debian 13 I figured a quick PR would be acceptable. Let me know if there is more needed/wanted here.

Tested this on my main system (previously 24.04 running XO, upgraded to 26.04) as well as on a fresh 24.04 VM, a fresh 26.04 VM and a fresh Debian 13 VM. Install/update works as expected.

@jenswegar

Copy link
Copy Markdown

Did the same changes to install on a fresh Ubuntu 26 LTS and seems to work OK, so upvote for merging this PR

@batinicaz

Copy link
Copy Markdown
Contributor Author

So the build failure is not related to this change, it's the default version of node on the runner being picked up which is v20:

error @xen-orchestra/disk-cli@2.0.0: The engine "node" is incompatible with this module. Expected version ">=22.3". Got "20.20.2"
error Found incompatible module.

I've pushed an extra commit to remove the default node install and related tools as well as upload the build logs on failure for easier debugging. Let me know if you'd prefer to solve this differently.

@MrGrymReaper

MrGrymReaper commented May 30, 2026

Copy link
Copy Markdown

@batinicaz Actually try this as it will work much better and also be the recommended best practice, for when using runners. Especially given the images are immutable like what’s recommended best practice for when making backups. Structuring this like what I've specified will make dependabot's work much easier and your own.

- uses: actions/setup-node@v4
   with:
       node-version: 22

Using the above to ensure that NodeJS 22 over 24 and 20 is used with the latest Ubuntu images, version 20 has been removed from upcoming runner images. Default NodeJS switches on/by 16th June 2026 and fully removed on/by Late 2026.

@batinicaz

Copy link
Copy Markdown
Contributor Author

@batinicaz Actually try this as it will work much better and also be the recommended best practice, for when using runners. Especially given the images are immutable like what’s recommended best practice for when making backups. Structuring this like what I've specified will make dependabot's work much easier and your own.

- uses: actions/setup-node@v4
   with:
       node-version: 22

Using the above to ensure that NodeJS 22 over 24 and 20 is used with the latest Ubuntu images, version 20 has been removed from upcoming runner images. Default NodeJS switches on/by 16th June 2026 and fully removed on/by Late 2026.

I opted for the remove because the action is testing the script, so testing the installation of node via the script felt “more correct” from that testing perspective. Totally agree from a pure approach to GHA the setup node action approach is best practice.

I tested the setup node version with v6 as that's the latest, and it works too (script upgrades to 24), so happy to go with whichever @ronivay prefers to get this merged 🙂

@ronivay

ronivay commented Aug 4, 2026

Copy link
Copy Markdown
Owner

@batinicaz Actually try this as it will work much better and also be the recommended best practice, for when using runners. Especially given the images are immutable like what’s recommended best practice for when making backups. Structuring this like what I've specified will make dependabot's work much easier and your own.

- uses: actions/setup-node@v4
   with:
       node-version: 22

Using the above to ensure that NodeJS 22 over 24 and 20 is used with the latest Ubuntu images, version 20 has been removed from upcoming runner images. Default NodeJS switches on/by 16th June 2026 and fully removed on/by Late 2026.

I opted for the remove because the action is testing the script, so testing the installation of node via the script felt “more correct” from that testing perspective. Totally agree from a pure approach to GHA the setup node action approach is best practice.

I tested the setup node version with v6 as that's the latest, and it works too (script upgrades to 24), so happy to go with whichever @ronivay prefers to get this merged 🙂

Hey,

Since the script should definitely replace any preinstalled node from ubuntu system, removing anything via github actions or defining a static version doesn't sound correct. If correct node version wasn't installed to the runner, that's something that needs to be debugged instead.

@batinicaz

Copy link
Copy Markdown
Contributor Author

@ronivay

The issue is specific to the github actions runner setup and the path evaluation.

If you look at the debug run I did you can see the failure mode: https://github.com/batinicaz/XenOrchestraInstallerUpdater/actions/runs/26183332098/job/77032016580

On a real Debian/Ubuntu host, distro node lives at /usr/bin/node and the nodesource package overwrites it in place. /usr/local/bin/node is not apt-managed so to fix it in the script you'd need to always remove that file which feels wrong to me. Is that what you're asking for instead or have I misunderstood?

@ronivay

ronivay commented Aug 4, 2026

Copy link
Copy Markdown
Owner

@ronivay

The issue is specific to the github actions runner setup and the path evaluation.

If you look at the debug run I did you can see the failure mode: https://github.com/batinicaz/XenOrchestraInstallerUpdater/actions/runs/26183332098/job/77032016580

On a real Debian/Ubuntu host, distro node lives at /usr/bin/node and the nodesource package overwrites it in place. /usr/local/bin/node is not apt-managed so to fix it in the script you'd need to always remove that file which feels wrong to me. Is that what you're asking for instead or have I misunderstood?

Yeah i'm wondering why this started to be an issue now, it has worked fine in the past although the runners have had older node version already. Looks like github deprecated node 20 recently and runners had both 20 and 24 available for some time which might explain this. Since mid june everything should use node 24 so this might not be an issue anymore. Could you try without the workflow modifications if the issue is there anymore.

@batinicaz

Copy link
Copy Markdown
Contributor Author

It's because of the timing of when this ran. The bug has always been there it's just been masked because the node version preinstalled with the runner meets the requirements XO needed so the fact that it was at the front of the path and got used went un-noticed.

Looks like the version got bumped in May: actions/runner-images#14029

So with it moving to 22 that should meet the XO requirements and no longer fail.

It will still be a lingering issue though as it's not going to be using the node version installed by the script. Don't want this to block the unrelated change of supporting Ubuntu 26 so just going to drop that change as asked 🙂

@batinicaz
batinicaz force-pushed the feature/ubuntu-26-04-support branch from fbf9578 to b2c19d0 Compare August 4, 2026 14:48
@ronivay

ronivay commented Aug 4, 2026

Copy link
Copy Markdown
Owner

Too bad old action logs aren't available but i could swear the node was updating even before from 20 to 22 and later on to 24 (what script is expecting since january) without issues. But anyway if this becomes an issue i'd rather solve this in a separate PR than here

@ronivay
ronivay merged commit 3c2a24b into ronivay:master Aug 4, 2026
3 of 5 checks passed
@batinicaz
batinicaz deleted the feature/ubuntu-26-04-support branch August 4, 2026 15:41
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.

4 participants