cloudapi: Make sigmd5 in PackageMetadata optional
In order to reuse PackageMetadata with DepsolveResponse and not include unused fields this changes the sigmd5 entry to an optional field. This doesn't effect the use of PackageMetadata in the Compose response since it is always set, and it allows it to be omitted in the response for depsolving. Also adds a basic test for stagesToPackageMetadata Related: RHEL-60125
This commit is contained in:
parent
08dc5f3041
commit
4f3c93ef1e
4 changed files with 188 additions and 70 deletions
|
|
@ -674,7 +674,7 @@ func stagesToPackageMetadata(stages []osbuild.RPMStageMetadata) []PackageMetadat
|
|||
Release: rpm.Release,
|
||||
Epoch: rpm.Epoch,
|
||||
Arch: rpm.Arch,
|
||||
Sigmd5: rpm.SigMD5,
|
||||
Sigmd5: common.ToPtr(rpm.SigMD5),
|
||||
Signature: osbuild.RPMPackageMetadataToSignature(rpm),
|
||||
},
|
||||
)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue