-
Notifications
You must be signed in to change notification settings - Fork 4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(cdk-assets): context path not honored by Docker asset build (#6957)
Prior v1.29.0, the context passed to the docker build command was always the current working directory. In v1.29.0, this was changed to be the directory the user passed when instantiating the asset. However, docker doesn't respect the context passed to the build command when the `--file` argument is also passed. This broke assets for users passing the `file` prop when constructing a `DockerImageAsset`. This is fixed by changing the current working directory of the `docker build` command and passing that context as `.`. Then docker uses the current working directory as the context and correctly finds the image definition file from the `file` prop. An existing integration test in the framework covers this case, but does not fail unless the stack is deployed fresh since the asset isn't rebuilt when the hash is not changed. Fix: #6954 #6814
- Loading branch information
1 parent
73899a9
commit 1edd507
Showing
3 changed files
with
14 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters