Skip to content
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

Copy a bundle with a relocation map to another registry #108

Closed
carolynvs opened this issue Jun 7, 2021 · 2 comments · Fixed by #109
Closed

Copy a bundle with a relocation map to another registry #108

carolynvs opened this issue Jun 7, 2021 · 2 comments · Fixed by #109

Comments

@carolynvs
Copy link
Collaborator

Here's the scenario that a Porter user is encountering:

  1. Push a bundle to a public registry, example/mybun:v1.0.0
  2. Copy the bundle to local registry, localhost:5000/mybun:v1.0.0. The copy now has a relocation map that maps example/mybun-invocation-image:v1.0.0 => localhost:5000/mybun-invocation-image:v1.0.0.
  3. Disconnect your internet connection.
  4. Copy the bundle from localhost:5000/mybun:v1.0.0 to localhost:5000/newbun:v1.0.0.

The copy fails because it tries to copy the invocation image from its original location defined in the bundle, instead of copying the relocated invocation image.

I'm not sure if there is a way to make this work right now? It seems like FixupBundle should take a relocation map for the bundle, and take any relocations into account before pulling and copying images?

@carolynvs
Copy link
Collaborator Author

Oh I just found WithRelocationMap! I think that will do what I need.

@carolynvs
Copy link
Collaborator Author

I think that there is a bug in the implementation that causes the relocation map to be ignored. I have a fix locally that I'll submit in a bit as soon as I figure out how to test the fix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant