2
0
mirror of https://github.com/linka-cloud/d2vm.git synced 2026-01-24 02:25:04 +00:00

feat: add AlmaLinux and Rocky Linux support

Signed-off-by: Adphi <philippe.adrien.nousse@gmail.com>
This commit is contained in:
2026-01-22 09:51:04 +01:00
parent 1e58d4dc42
commit 6e54c731a4
11 changed files with 42 additions and 17 deletions

View File

@@ -102,7 +102,7 @@ func NewDockerfile(release OSRelease, img, password string, networkManager Netwo
if networkManager == NetworkManagerNetplan {
return d, fmt.Errorf("netplan is not supported on alpine")
}
case ReleaseCentOS:
case ReleaseCentOS, ReleaseRocky, ReleaseAlmaLinux:
d.tmpl = centOSDockerfileTemplate
net = NetworkManagerNone
if networkManager != "" && networkManager != NetworkManagerNone {
@@ -112,7 +112,7 @@ func NewDockerfile(release OSRelease, img, password string, networkManager Netwo
return Dockerfile{}, fmt.Errorf("unsupported distribution: %s", release.ID)
}
if d.NetworkManager == "" {
if release.ID != ReleaseCentOS {
if release.ID != ReleaseCentOS && release.ID != ReleaseRocky && release.ID != ReleaseAlmaLinux {
logrus.Warnf("no network manager specified, using distribution defaults: %s", net)
}
d.NetworkManager = net