-
Notifications
You must be signed in to change notification settings - Fork 100
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix(sync): fixed skipping docker images when they already synced #1521
fix(sync): fixed skipping docker images when they already synced #1521
Conversation
0b49a95
to
c10f7dd
Compare
need to add tests |
c10f7dd
to
980fd33
Compare
Codecov Report
@@ Coverage Diff @@
## main #1521 +/- ##
========================================
Coverage 91.19% 91.19%
========================================
Files 114 114
Lines 22757 22862 +105
========================================
+ Hits 20753 20849 +96
- Misses 1495 1501 +6
- Partials 509 512 +3
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
073903f
to
b166b05
Compare
b166b05
to
487aae5
Compare
Thank you for doing this. I was debugging the same behavior as #1490 when mirroring from Amazon ECR (on-demand). Came across your PR as I was hacking in this support. |
20d6240
to
af93db2
Compare
before syncing an image we first check if it's already present in our storage to do that we get the manifest from remote and compare it with the local one but in the case of syncing docker images, because the conversion to OCI format is done while syncing, we get a docker manifest before conversion, so sync detects that local manifest and remote one are different, so it starts syncing again. to overcome this, convert remote docker manifests to OCI manifests and then compare. Signed-off-by: Petu Eusebiu <[email protected]>
af93db2
to
40f8675
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
I had patched in your changes over the latest
Thanks again 👍🏼 |
What type of PR is this?
bug
Which issue does this PR fix:
#1490
What does this PR do / Why do we need it:
currently docker images are downloaded every time, because comparison between remote and local is done before conversion of docker images to oci.
convert docker manifests to oci manifests before syncing, compare with local one and skip if it's already synced
If an issue # is not available please add repro steps and logs showing the issue:
Testing done on this change:
Automation added to e2e:
Will this break upgrades or downgrades?
no
Does this PR introduce any user-facing change?:
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.