Skip to content

Commit 3734760

Browse files
author
Mayank Singh
committed
update distro id to match os-release
Signed-off-by: Mayank Singh <mayansingh@microsoft.com>
1 parent 284c8d9 commit 3734760

File tree

3 files changed

+15
-14
lines changed

3 files changed

+15
-14
lines changed

pkg/util/helpers_linux.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ func getOSVersion(osReleasePath string) (string, error) {
7272
return getDebianVersion(osReleaseMap), nil
7373
case "flatcar":
7474
return getDebianVersion(osReleaseMap), nil
75-
case "acl":
75+
case "azurecontainerlinux":
7676
return getDebianVersion(osReleaseMap), nil
7777
default:
7878
return "", fmt.Errorf("unsupported ID in /etc/os-release: %q", osReleaseMap["ID"])

pkg/util/helpers_linux_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -101,9 +101,9 @@ func TestGetOSVersionLinux(t *testing.T) {
101101
expectErr: false,
102102
},
103103
{
104-
name: "acl",
104+
name: "azurecontainerlinux",
105105
fakeOSReleasePath: "testdata/os-release-acl",
106-
expectedOSVersion: "acl 4459.2.2",
106+
expectedOSVersion: "azurecontainerlinux 3.0.20260311",
107107
expectErr: false,
108108
},
109109
{

pkg/util/testdata/os-release-acl

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,14 @@
1-
NAME="Azure Container Linux"
2-
ID=acl
3-
ID_LIKE=flatcar
4-
VERSION=4459.2.2
5-
VERSION_ID=4459.2.2
6-
BUILD_ID=97-g545e29b39d
1+
NAME="Microsoft Azure Container Linux"
2+
ID=azurecontainerlinux
3+
ID_LIKE=azurelinux
4+
VERSION=3.0.20260311
5+
VERSION_ID=3.0.20260311
6+
BUILD_ID=053024-b84c192057-dirty
77
SYSEXT_LEVEL=1.0
8-
PRETTY_NAME="Azure Container Linux 4459.2.2+97-g545e29b39d (ACL)"
9-
ANSI_COLOR="38;5;75"
10-
HOME_URL="https://flatcar.org/"
11-
BUG_REPORT_URL="https://issues.flatcar.org"
8+
PRETTY_NAME="Microsoft Azure Container Linux 3.0.20260311+053024-b84c192057-dirty"
9+
ANSI_COLOR="1;34"
10+
HOME_URL="https://aka.ms/azurelinux"
11+
BUG_REPORT_URL="https://aka.ms/azurelinux"
12+
SUPPORT_URL="https://aka.ms/azurelinux"
1213
FLATCAR_BOARD="amd64-usr"
13-
CPE_NAME="cpe:2.3:o:acl-linux:acl_linux:4459.2.2+97-g545e29b39d:*:*:*:*:*:*:*"
14+
CPE_NAME="cpe:2.3:o:microsoft:azure_container_linux:3.0.20260311+053024-b84c192057-dirty:*:*:*:*:*:*:*"

0 commit comments

Comments
 (0)