aws / copilot-cli

The AWS Copilot CLI is a tool for developers to build, release and operate production ready containerized applications on AWS App Runner or Amazon ECS on AWS Fargate.
https://aws.github.io/copilot-cli/
Apache License 2.0
3.49k stars 406 forks source link

Is there someway to enable '--network=host' during the Docker build? #2566

Open chinchalinchin opened 3 years ago

chinchalinchin commented 3 years ago

I have an Angular frontend image that gets pre-rendered during the build. See here. While it's pre-rendering, it needs to be able to communicate with the backend container in order to consume some data that's used to populate the HTML templates.

I saw this: https://github.com/aws/copilot-cli/issues/1177

Which sort of solves the problem, but adds an extra step to the deployment process. I have to build the image manually before pushing it to ECS.

Is there any way to set the networking mode during docker build?

iamhopaul123 commented 3 years ago

Hello @chinchalinchin glad you found the workaround for this problem (though needs an extra step).

Unfortunately currently it is not possible to set the networking mode during docker build. I'll put this into our backlog and we prioritize our feature requests by the number of thumb-up. Thank you so much for you support for Copilot!