-
Notifications
You must be signed in to change notification settings - Fork 207
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
Add --cache-to
option to devcontainer build
command
#570
Add --cache-to
option to devcontainer build
command
#570
Conversation
@microsoft-github-policy-service agree |
453556d
to
074324a
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.
I've run CI on your changes and looks like there's a couple minor tweaks needed. Linter issues can be detected locally with yarn lint
. There's also a test issue but that probably just needs some minor reworking
2a070ff
to
eafbf64
Compare
Sorry! I fixed lint issue. Waiting for checks. |
@joshspicer |
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.
Thanks! I'll ask @chrmarti to take a quick peek to
@chrmarti |
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.
Thanks for the PR! Left a comment. Additionally:
-
Please add a check and error at
cli/src/spec-node/devContainersSpecCLI.ts
Line 620 in eafbf64
-
Should the flag also be added at
cli/src/spec-node/containerFeatures.ts
Line 90 in eafbf64
for (const buildArg in featureBuildInfo.buildArgs) {
Thanks for your review. I pushed two commits!
|
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.
Approving PR, thanks!
@joshspicer / @samruddhikhandale Could you take another look? Thanks.
@samruddhikhandale |
This seems to be missing from |
Close #563
I added
--cache-to
option todevcontainer build
command.If buildx is used for building image, we can pass
--cache-to
option in order to export and reuse buildx cache.Checks
docker buildx create --driver=docker-container --use
--cache-to
optionnode devcontainer.js build --workspace-folder . --cache-to=type=local,dest=/tmp/build-cache
ls /tmp/build-cache