Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
- What I did
The current
lkt pkg build
process is treated as:That is not quite as efficient as it could be. There is no reason to pull it from registry to local cache unless you really want it. Much of the time,
pkg build
really is just saying, "I want to build it if it doesn't exist anywhere", not "I also need it in my cache." This tends to bloat the cache unnecessarily.The change now does the following:
--pull
, in which case pull too)You still can get the current behaviour with
lkt pkg build --pull
, but now package building is not confused by default with cache filling.Of course, when you actually build an image with
lkt build
, it checks in the cache and, if not found, pulls it down anyways, solkt build
is unchanged.- How I did it
Added an option to
pkg build --pull
and changed the pull logic.- How to verify it
Run CI. Also tested manually.
- Description for the changelog
Default for building packages is not to pull from registry unless explicitly requested.