question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

DockerImageAsset is missing build context

See original GitHub issue
  • I’m submitting a …

    • 🪲 bug report
    • 🚀 feature request
    • 📚 construct library gap
    • ☎️ security issue or vulnerability => Please see policy
    • ❓ support request => Please see note at the top of this template.
  • What is the current behavior? If the current behavior is a 🪲bug🪲: Please provide the steps to reproduce

Right now there is not option to specify the build context for the docker build. E.g. if the Dockerfile requires files from .. the build context need to be at least ‘…’ instead of ‘.’ which is the default.

  • What is the expected behavior (or behavior of feature suggested)?

There should be an option to specify the context. This could be tricky, since CDK stages the files which would then mean to stage the entire build context.

  • What is the motivation / use case for changing the behavior or adding this feature?

It is an advanced use case for building docker images in for example mono-repositories where there are dependencies into other folders.

  • Please tell us about your environment:

    • CDK CLI Version: 0.36.0
    • Module Version: 0.36.0
    • OS: all
    • Language: TypeScript
  • Other information (e.g. detailed explanation, stacktraces, related issues, suggestions how to fix, links for us to have context, eg. associated pull-request, stackoverflow, gitter, etc)

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:8
  • Comments:8 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
eladbcommented, Nov 4, 2019

@SomayaB please assign all asset issues to me 😃

0reactions
SomayaBcommented, Mar 25, 2020

Closing for now since there hasn’t been a response in a while. Feel free to reopen.

Read more comments on GitHub >

github_iconTop Results From Across the Web

class DockerImageAsset (construct ... - AWS Documentation
Type: { [string]: string } (optional, default: no build args are passed). Build args to pass to the docker build command. Since Docker...
Read more >
CDK Assets - Docker load build context failing with Access ...
There is no error if I build the Docker image as is using the docker build command. I have checked the file permissions...
Read more >
Build context | Docker Documentation
The following example builds an image using a Dockerfile that is passed through stdin. No files are sent as build context to the...
Read more >
awslabs/aws-cdk - Gitter
cdk (stack file with new DockerImageAsset(this, 'MyBuildImage', ... I'd like to let people deploy this stack locally when there is no build asset....
Read more >
@aws-cdk/aws-ecr-assets - npm
Images are built from a local Docker context directory (with a ... DockerImageAsset is designed for seamless build & consumption of image ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found