internal/distro: make it possible to use rhsm with fedora

It should be possible to use rhsm with fedora repos as well.
This commit is contained in:
Martin Sehnoutka 2021-05-20 12:50:23 +02:00 committed by msehnout
parent 1ada606ed8
commit ac51c5087f

View file

@ -281,6 +281,11 @@ func sources(packages []rpmmd.PackageSpec) *osbuild.Sources {
fileSource := osbuild.FileSource{
URL: pkg.RemoteLocation,
}
if pkg.Secrets == "org.osbuild.rhsm" {
fileSource.Secrets = &osbuild.Secret{
Name: "org.osbuild.rhsm",
}
}
files.URLs[pkg.Checksum] = fileSource
}
return &osbuild.Sources{