Giter Club home page Giter Club logo

Comments (2)

joaopapereira avatar joaopapereira commented on June 26, 2024

Given the help text of the --file-exclude-defaults flag, I would be inclined to say that if the flag is present and excludes the .imgpkg folder when pushing the image to the registry the folder should not be present.
But my expectation when trying to exclude .imgpkg folder is that I would get an error, since this is part of the imgpkg internals.

IMHO I believe what we should do is give a different error message when you try to exclude the .imgpkg folder using --file-exclude-defaults. Something in the lines of Error: The folder .imgpkg cannot be excluded.

In my research, for this issue, I found out that you can push a bundle and ignore the .imgpkg folder which is a problem and the solution that I propose above could solve it.
The example:

$ imgpkg push -b localhost:5000/test -f examples/basic-bundle --file-exclude-defaults .imgpkg
dir: .
file: config.yml
Pushed 'localhost:5000/test@sha256:319deaae5b3ce1633f14000f57144ebe1c73fbd4eb3d37874910335a92ab32ca'
Succeeded


$ imgpkg pull -b localhost:5000/test -o tmp
Pulling image 'localhost:5000/test@sha256:319deaae5b3ce1633f14000f57144ebe1c73fbd4eb3d37874910335a92ab32ca'
Extracting layer 'sha256:53484d40f83668beb17852cc4d95b4530fad5aca908446288136b75b6aa3e06b' (1/1)

Error: Rewriting image lock file: Reading image lock file: open tmp/.imgpkg/images.yml: no such file or directory

from imgpkg.

danielhelfand avatar danielhelfand commented on June 26, 2024

Agree with @joaopapereira that the error message for this specific case makes sense. It should be easy enough to catch if .imgpkg is part of the path included with --file-exclude-defaults and error out to explain to the user why not to do this.

from imgpkg.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.