Closed nabuskey closed 9 months ago
I think we should populate GitServerStatus
to keep both the imageId and the imageDigest. the data will come in handy later on
well actually thinking about it more and looking at the code, the image ID is rather fixed, knowing the GitResource. for the test to pass, we just need to make sure the reference contains both the id and its SHA256. I will send a fix for this.
The image ID field is filled with image digest, not image ID.
https://github.com/cnoe-io/idpbuilder/blob/1a9acbb3d71ac797dae14bbb32533507b30538e4/pkg/controllers/gitserver/image.go#L53-L62
PushImage
returns: https://github.com/cnoe-io/idpbuilder/blob/1a9acbb3d71ac797dae14bbb32533507b30538e4/pkg/apps/image.go#L55-L63Because digest is passed to Docker client, the test fails. https://github.com/cnoe-io/idpbuilder/blob/1a9acbb3d71ac797dae14bbb32533507b30538e4/pkg/controllers/gitserver/image_test.go#L55
Did we meant to return the digest instead of id in this? https://github.com/cnoe-io/idpbuilder/blob/1a9acbb3d71ac797dae14bbb32533507b30538e4/pkg/apps/image.go#L23