Repository navigation
Conversation
AdaAibaby
requested review from
ValentaTomas,
dobrac and
jakubno
as code owners
November 13, 2026 14:29
openEuler is an RPM/dnf, systemd distribution and the upstream base for a large part of the domestic server ecosystem. Its /etc/os-release declares ID=openEuler (mixed case; provision.sh matches it verbatim without lowercasing) and carries no ID_LIKE, so template builds on an openEuler base currently fall through to the "unsupported base image distribution" error with no best-effort fallback. Add an openEuler profile to the distro registry. It mirrors the RHEL/TencentOS family (dnf -> microdnf -> yum install fallback, systemd at /usr/lib/systemd/systemd, wheel admin group, update-ca-trust bundle refresh) with one verified package-name difference: openEuler ships shadow, not shadow-utils. parity_test.go gains an openeuler entry for every capability so the package set stays in lockstep with the other families; TestOpenEulerProfile pins the mixed-case id and the shadow swap; README lists openEuler as supported. Verified against openeuler/openeuler:22.03 (amd64): - /etc/os-release: ID="openEuler", no ID_LIKE - dnf transaction for the full profile package set resolves cleanly (Install 166 Packages, 37 M; no unresolved packages) - shadow-utils is absent from the repos; shadow exists (hence the swap) - dnf and yum both present - go test ./.../base/distro/ passes (parity trio + the generic RPM-fallback and selector coverage tests, plus TestOpenEulerProfile)
AdaAibaby
force-pushed
the
feat/openeuler-distro-support
branch
from
November 13, 2026 14:42
962b4db to
5962a67
Compare
This branch has not been deployed
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.
What
Add an openEuler profile to the template-build distro registry, so builds on an openEuler base image are officially supported instead of failing as an unsupported distribution.
This follows the same pattern as the TencentOS/OpenCloudOS support (#3747 / e78f6cf): a declarative
Profilekeyed on/etc/os-releaseID, plus aparity_test.gocapability entry per family.Why
openEuler is an RPM/dnf, systemd distribution and the upstream base for a large part of the domestic server ecosystem (e.g. Kylin V10 SP lineage). Its
/etc/os-releasedeclaresID=openEulerand carries noID_LIKE, so today an openEuler base has no matching profile and no ID_LIKE fallback — provisioning exits withunsupported base image distribution.How
The profile mirrors the RHEL/TencentOS family (
dnf → microdnf → yuminstall fallback, systemd at/usr/lib/systemd/systemd,wheeladmin group,update-ca-trustbundle refresh) with one verified difference: openEuler shipsshadow, notshadow-utils.parity_test.gogains anopeneulerentry for every capability so the package set can't drift from the other families.Two gotchas confirmed empirically and encoded:
provision.shsetsE2B_DISTRO_ID="${ID:-unknown}"with no lowercasing, and openEuler's ID is mixed-case, so the profile lists"openEuler"verbatim.shadowvsshadow-utils— the RHEL-family nameshadow-utilsdoes not exist in openEuler repos.Tested (openeuler/openeuler:22.03, amd64)
go test ./packages/orchestrator/pkg/template/build/phases/base/distro/ -v— all pass, including the genericTestRPMProfilesFallBackFromDnf,TestSelectorCoversIDsAndRejects, and the parity trio (TestEveryFamilyCoversEveryCapability,TestNoUnmappedPackages,TestCapabilitiesTrackTheProfileRegistry) now covering openEuler.Scope
Two files:
distro/distro.go(+profile) anddistro/parity_test.go(+openeuler capability entries). No behavior change for any existing distro./cc @ryan-sana Looking forward to your code review.