76 lines
3.4 KiB
Diff
76 lines
3.4 KiB
Diff
From d38fff3c8949da2bcb8628dbe67019034fd41c8b Mon Sep 17 00:00:00 2001
|
|
From: Josue David Hernandez Gutierrez <josue.d.hernandez@oracle.com>
|
|
Date: Fri, 15 Nov 2024 19:04:22 +0000
|
|
Subject: [PATCH 9/9] Simplify repo name removing minor versions
|
|
|
|
Rename ol-810.json to ol-8.json and ol-95.json to ol-9.json
|
|
|
|
Signed-off-by: Josue David Hernandez Gutierrez <josue.d.hernandez@oracle.com>
|
|
Reviewed-by: Alex Burmashev <alexander.burmashev@oracle.com>
|
|
---
|
|
repositories/{ol-810.json => ol-8.json} | 0
|
|
repositories/{ol-95.json => ol-9.json} | 0
|
|
.../osbuild/images/pkg/distro/rhel/distribution.go | 4 ++--
|
|
.../osbuild/images/pkg/distro/rhel/rhel9/distro.go | 6 +++---
|
|
4 files changed, 5 insertions(+), 5 deletions(-)
|
|
rename repositories/{ol-810.json => ol-8.json} (100%)
|
|
rename repositories/{ol-95.json => ol-9.json} (100%)
|
|
|
|
diff --git a/repositories/ol-810.json b/repositories/ol-8.json
|
|
similarity index 100%
|
|
rename from repositories/ol-810.json
|
|
rename to repositories/ol-8.json
|
|
diff --git a/repositories/ol-95.json b/repositories/ol-9.json
|
|
similarity index 100%
|
|
rename from repositories/ol-95.json
|
|
rename to repositories/ol-9.json
|
|
diff --git a/vendor/github.com/osbuild/images/pkg/distro/rhel/distribution.go b/vendor/github.com/osbuild/images/pkg/distro/rhel/distribution.go
|
|
index 90e88b9..404a652 100644
|
|
--- a/vendor/github.com/osbuild/images/pkg/distro/rhel/distribution.go
|
|
+++ b/vendor/github.com/osbuild/images/pkg/distro/rhel/distribution.go
|
|
@@ -140,9 +140,9 @@ func NewDistribution(name string, major, minor int) (*Distribution, error) {
|
|
}
|
|
case "ol":
|
|
rd = &Distribution{
|
|
- name: fmt.Sprintf("ol-%d.%d", major, minor),
|
|
+ name: fmt.Sprintf("ol-%d", major),
|
|
product: "Oracle Linux",
|
|
- osVersion: fmt.Sprintf("%d.%d", major, minor),
|
|
+ osVersion: fmt.Sprintf("%d", major),
|
|
releaseVersion: fmt.Sprintf("%d", major),
|
|
modulePlatformID: fmt.Sprintf("platform:el%d", major),
|
|
vendor: "redhat",
|
|
diff --git a/vendor/github.com/osbuild/images/pkg/distro/rhel/rhel9/distro.go b/vendor/github.com/osbuild/images/pkg/distro/rhel/rhel9/distro.go
|
|
index 9fb03d1..c2a2123 100644
|
|
--- a/vendor/github.com/osbuild/images/pkg/distro/rhel/rhel9/distro.go
|
|
+++ b/vendor/github.com/osbuild/images/pkg/distro/rhel/rhel9/distro.go
|
|
@@ -43,14 +43,14 @@ var (
|
|
func distroISOLabelFunc(t *rhel.ImageType) string {
|
|
const RHEL_ISO_LABEL = "RHEL-%s-%s-0-BaseOS-%s"
|
|
const CS_ISO_LABEL = "CentOS-Stream-%s-BaseOS-%s"
|
|
- const OL_ISO_LABEL = "OL-%s-%s-dvd-%s"
|
|
+ const OL_ISO_LABEL = "OL-%s-dvd-%s"
|
|
|
|
if t.IsRHEL() {
|
|
osVer := strings.Split(t.Arch().Distro().OsVersion(), ".")
|
|
return fmt.Sprintf(RHEL_ISO_LABEL, osVer[0], osVer[1], t.Arch().Name())
|
|
}else if t.Arch().Distro().Name() == "ol" {
|
|
osVer := strings.Split(t.Arch().Distro().OsVersion(), ".")
|
|
- return fmt.Sprintf(RHEL_ISO_LABEL, osVer[0], osVer[1], t.Arch().Name())
|
|
+ return fmt.Sprintf(RHEL_ISO_LABEL, osVer[0], t.Arch().Name())
|
|
} else {
|
|
return fmt.Sprintf(CS_ISO_LABEL, t.Arch().Distro().Releasever(), t.Arch().Name())
|
|
}
|
|
@@ -298,7 +298,7 @@ func ParseID(idStr string) (*distro.ID, error) {
|
|
}
|
|
|
|
// RHEL uses minor version
|
|
- if (id.Name == "rhel" || id.Name == "ol") && id.MinorVersion == -1 {
|
|
+ if id.Name == "rhel" && id.MinorVersion == -1 {
|
|
return nil, fmt.Errorf("rhel requires minor version, but got: %d", id.MinorVersion)
|
|
}
|
|
|
|
--
|
|
2.43.5
|
|
|