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

feat(image): support for the --cache-from build flag #38

Conversation

esatterwhite
Copy link
Owner

includes support for the build flags cache-from

fixes: #35

includes a new config option `dockerBuildFlags` that allow injecting
arbitrary flags to the build command. Internally, the `arg` function on
the docker image class which is used to accumulate the `build-arg`
options has been converted to make use of the generic flag method.

Flags are normalized in this fashion.

* If the key does not start with a `-` it will be prepended
* all occurences of `_` will be re-written as `-`
* Single letter keys are considered shorthands e.g. `p` becomes `-p`
* Multi letter keys are considered long form e.g. `foo_bar` becomes `--foo-bar`
* If the value is an array, the flag is repeated for each occurance
* A `null` value may be used to omit the value and only inject the flag itself
@esatterwhite esatterwhite linked an issue Jul 10, 2023 that may be closed by this pull request
@esatterwhite esatterwhite force-pushed the 35-support-for-cache-from-argument-or-custom-docker-cli-arguments branch from 1593217 to c51629f Compare July 10, 2023 21:24
@esatterwhite esatterwhite added the enhancement New feature or request label Jul 10, 2023
includes support for the build flags cache-from and cache-to

fixes: #35
@esatterwhite esatterwhite force-pushed the 35-support-for-cache-from-argument-or-custom-docker-cli-arguments branch from c51629f to f2c566f Compare July 11, 2023 14:30
@esatterwhite esatterwhite merged commit efae32d into main Jul 11, 2023
4 checks passed
@esatterwhite esatterwhite deleted the 35-support-for-cache-from-argument-or-custom-docker-cli-arguments branch July 11, 2023 14:42
@github-actions
Copy link

🎉 This PR is included in version 4.4.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request released
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support for --cache-from argument, or custom docker cli arguments
1 participant