distro: rename tarInstaller vars to imageInstaller

The image type is only ever known (externally) as image-installer.
Renaming the internal variables and functions to reflect the name makes
the code easier to navigate.
This commit is contained in:
Achilleas Koutsou 2022-04-05 02:34:42 +02:00 committed by Christian Kellner
parent 8316cf7ef0
commit a76f7a64dc
4 changed files with 8 additions and 8 deletions

View file

@ -875,7 +875,7 @@ func newDistro(name, modulePlatformID, ostreeRef string) distro.Distro {
payloadPipelines: []string{"os", "root-tar"},
exports: []string{"root-tar"},
}
tarInstallerImgTypeX86_64 := imageType{
imageInstallerImgTypeX86_64 := imageType{
name: "image-installer",
filename: "installer.iso",
mimeType: "application/x-iso9660-image",
@ -887,13 +887,13 @@ func newDistro(name, modulePlatformID, ostreeRef string) distro.Distro {
rpmOstree: false,
bootISO: true,
bootable: true,
pipelines: tarInstallerPipelines,
pipelines: imageInstallerPipelines,
buildPipelines: []string{"build"},
payloadPipelines: []string{"os", "anaconda-tree", "bootiso-tree", "bootiso"},
exports: []string{"bootiso"},
}
x86_64.addImageTypes(qcow2ImgType, vhdImgType, vmdkImgType, openstackImgType, amiImgTypeX86_64, ec2ImgTypeX86_64, ec2HaImgTypeX86_64, tarImgType, tarInstallerImgTypeX86_64, edgeCommitImgType, edgeInstallerImgType, edgeOCIImgType, edgeRawImgType, edgeSimplifiedInstallerImgType, ociImageType)
x86_64.addImageTypes(qcow2ImgType, vhdImgType, vmdkImgType, openstackImgType, amiImgTypeX86_64, ec2ImgTypeX86_64, ec2HaImgTypeX86_64, tarImgType, imageInstallerImgTypeX86_64, edgeCommitImgType, edgeInstallerImgType, edgeOCIImgType, edgeRawImgType, edgeSimplifiedInstallerImgType, ociImageType)
aarch64.addImageTypes(qcow2ImgType, openstackImgType, amiImgTypeAarch64, ec2ImgTypeAarch64, tarImgType, edgeCommitImgType, edgeInstallerImgType, edgeOCIImgType, edgeRawImgType, edgeSimplifiedInstallerImgType)
ppc64le.addImageTypes(qcow2ImgType, tarImgType)
s390x.addImageTypes(qcow2ImgType, tarImgType)

View file

@ -504,7 +504,7 @@ func edgeInstallerPipelines(t *imageType, customizations *blueprint.Customizatio
return pipelines, nil
}
func tarInstallerPipelines(t *imageType, customizations *blueprint.Customizations, options distro.ImageOptions, repos []rpmmd.RepoConfig, packageSetSpecs map[string][]rpmmd.PackageSpec, rng *rand.Rand) ([]osbuild.Pipeline, error) {
func imageInstallerPipelines(t *imageType, customizations *blueprint.Customizations, options distro.ImageOptions, repos []rpmmd.RepoConfig, packageSetSpecs map[string][]rpmmd.PackageSpec, rng *rand.Rand) ([]osbuild.Pipeline, error) {
pipelines := make([]osbuild.Pipeline, 0)
pipelines = append(pipelines, *buildPipeline(repos, packageSetSpecs[buildPkgsKey]))

View file

@ -865,7 +865,7 @@ func newDistro(name, modulePlatformID, ostreeRef string) distro.Distro {
payloadPipelines: []string{"os", "root-tar"},
exports: []string{"root-tar"},
}
tarInstallerImgTypeX86_64 := imageType{
imageInstallerImgTypeX86_64 := imageType{
name: "image-installer",
filename: "installer.iso",
mimeType: "application/x-iso9660-image",
@ -877,7 +877,7 @@ func newDistro(name, modulePlatformID, ostreeRef string) distro.Distro {
rpmOstree: false,
bootISO: true,
bootable: true,
pipelines: tarInstallerPipelines,
pipelines: imageInstallerPipelines,
buildPipelines: []string{"build"},
payloadPipelines: []string{"os", "anaconda-tree", "bootiso-tree", "bootiso"},
exports: []string{"bootiso"},
@ -886,7 +886,7 @@ func newDistro(name, modulePlatformID, ostreeRef string) distro.Distro {
ociImgtype := qcow2ImgType
ociImgtype.name = "oci"
x86_64.addImageTypes(qcow2ImgType, vhdImgType, vmdkImgType, openstackImgType, amiImgTypeX86_64, ec2ImgTypeX86_64, ec2HaImgTypeX86_64, ec2SapImgTypeX86_64, tarImgType, tarInstallerImgTypeX86_64, edgeCommitImgType, edgeInstallerImgType, edgeOCIImgType, ociImgtype)
x86_64.addImageTypes(qcow2ImgType, vhdImgType, vmdkImgType, openstackImgType, amiImgTypeX86_64, ec2ImgTypeX86_64, ec2HaImgTypeX86_64, ec2SapImgTypeX86_64, tarImgType, imageInstallerImgTypeX86_64, edgeCommitImgType, edgeInstallerImgType, edgeOCIImgType, ociImgtype)
aarch64.addImageTypes(qcow2ImgType, openstackImgType, amiImgTypeAarch64, ec2ImgTypeAarch64, tarImgType, edgeCommitImgType, edgeOCIImgType)
ppc64le.addImageTypes(qcow2ImgType, tarImgType)
s390x.addImageTypes(qcow2ImgType, tarImgType)

View file

@ -636,7 +636,7 @@ func edgeInstallerPipelines(t *imageType, customizations *blueprint.Customizatio
return pipelines, nil
}
func tarInstallerPipelines(t *imageType, customizations *blueprint.Customizations, options distro.ImageOptions, repos []rpmmd.RepoConfig, packageSetSpecs map[string][]rpmmd.PackageSpec, rng *rand.Rand) ([]osbuild.Pipeline, error) {
func imageInstallerPipelines(t *imageType, customizations *blueprint.Customizations, options distro.ImageOptions, repos []rpmmd.RepoConfig, packageSetSpecs map[string][]rpmmd.PackageSpec, rng *rand.Rand) ([]osbuild.Pipeline, error) {
pipelines := make([]osbuild.Pipeline, 0)
pipelines = append(pipelines, *buildPipeline(repos, packageSetSpecs[buildPkgsKey]))