Image re-mirroring requires manual redeployment

Hi!

We use our own pipeline to build images. The same pipeline updates the corresponding Qovery containers and jobs with the new tags, and redeploys the environment via Qovery CLI.
The registry.image_retention_time in one of our clusters is set to 7 days.
The images in the original source ECR repository (from which images get mirrored) do not get deleted (in the case being described).
Today one of our services could not get back up after an implicit restart, which was triggered by EKS, I presume.
The pod status said “:x: ImagePullBackOff:Back-off pulling image from image registry. Re-deploy the service”.
After looking at the corresponding mirror repo in ECR, the mirrored image is no longer there since it was mirrored 8 days ago, when the retention time is 7 days. The original image, however, is still present in the source repository.

Based on a chat in our shared Slack channel, we were under impression that this exact situation is handled by Qovery automatically and the image simply gets re-mirrored without the need for a manual redeployment, but it appears to not be the case. Is this intended? Is this something that could be changed or fixed in the future?

Hi @daniilsvetlov,

there might have been a misunderstanding since there is no automatic re-mirroring process in place and your image gets deleted after 7 days. The re-mirroring is done only if a new deployment of the service is triggered again.

I see you are using the Cluster mirroring mode. While on the Service mode we can guarantee that the images will be deleted when they are not needed anymore (and thus you can set the retention to 0 - meaning never delete) on the Cluster mode we don’t manage the deletion automatically when they are not needed anymore (as explained in our doc here). This is why we suggest to find the right value for the retention depending on how frequently you deploy a service.

FYI, we are working on a feature to share across environments an image built via the qovery CI and we will probably implement a way to clean properly the images for containers mirrored in the Cluster mode too.

1 Like

Thanks for clarification @a_carrano

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.