How to speed up Docker 1sec → 100ms

Hi all.

Whenever I run my yii project in Docker (using docker-compose as provided in the demo applications) it is slow. Is it usual that Docker is slow (even if running on DigitalOcean) or can I do something to speed it up let’s say 10x? Usual request takes 1sec.

When I copy the same project to the productive server where Docker is not used, requests take 20-300ms which is much better.

Update: So the problem was caused by the port. My application was running on 4080 and when I changed it to 80 in docker-compose.yml, the website has become extremely fast.

1 Like