Why is Symfony so slow in Docker container?

Why is Symfony so slow in Docker container?

Running a composer (PHP) update in a container takes much longer than on the host. In the container we usually hit timeouts when updating huge git repos like twbs/bootstrap. Same for npm install, bundle install, browserify, etc. Ok, that’s why a Symfony application is very slow in a Docker container!

Can a docker container use more memory than the host?

By default, a container has no resource constraints and can use as much of a given resource as the host’s kernel scheduler allows. Docker provides ways to control how much memory, or CPU a container can use, setting runtime configuration flags of the docker run command.

How to limit the resources of a docker container?

Limit a container’s resources. By default, a container has no resource constraints and can use as much of a given resource as the host’s kernel scheduler allows. Docker provides ways to control how much memory, CPU, or block IO a container can use, setting runtime configuration flags of the docker run command.

Which is better for performance, AuFS or Docker?

Docker volumes have noticeably better performance than files stored in AUFS. Docker’s NAT also introduces overhead for workloads with high packet rates. These features represent a tradeoff between ease of management and performance and should be considered on a case-by-case basis.

Why is Docker for Mac not using NFS?

@ianks There are several reasons for not using NFS. The issue is current one Docker for Mac using still have own problems. Give the team more time to solve that. As @andrerom mentioned above, you still can use workarounds. I’m still using docker/toolbox and it’s working fine.

Is there way to duplicate vendor in Docker?

For now you can use duplicate vendor in both docker and out of docker with manual synchronization. So that PHPStorm uses local version and docker uses volume in VM. I tried :cached on building Swift toolchain for Linux that source codes are placed in mac volume.