Skip to content

Commit be26909

Browse files
authored
fix: add fedora to prereqs list (#419)
1 parent ced4c2f commit be26909

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

internal/utils/prereqs/prereqs.go

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,11 +20,15 @@ import (
2020
type PackagePrereq struct {
2121
// List of Azure Linux distro packages that must be installed to provide this prerequisite.
2222
AzureLinuxPackages []string
23+
// List of Fedora distro packages that must be installed to provide this prerequisite.
24+
FedoraPackages []string
2325
}
2426

2527
const (
2628
// The OS ID of Azure Linux.
2729
OSIDAzureLinux = "azurelinux"
30+
// The OS ID of Fedora.
31+
OSIDFedora = "fedora"
2832
)
2933

3034
// ErrMissingExecutable is returned when a required executable cannot be found or acquired.
@@ -112,6 +116,8 @@ func (p *PackagePrereq) selectInstallerAndPackagesForHost(
112116
switch osid {
113117
case OSIDAzureLinux:
114118
return "tdnf", p.AzureLinuxPackages, nil
119+
case OSIDFedora:
120+
return "dnf", p.FedoraPackages, nil
115121
default:
116122
return installer, packageNames, fmt.Errorf("host OS not supported: '%s'", osid)
117123
}

0 commit comments

Comments
 (0)