DEV Community

Cover image for How do YOU speed up Docker (Compose) on Mac?
JavaScript Room
JavaScript Room

Posted on

How do YOU speed up Docker (Compose) on Mac?

Hey everyone!

As I see, the performance of docker/docker-compose is a pain point for many developers and devops folks. I'm on the list, for sure. I still have Docker Compose running super slow on my fresh Mac Air.

How about you? Are you okay with your Docker's performance? And what tricks helped you to configure it nicely?

Top comments (12)

Collapse
 
devhead profile image
dev-head • Edited

Yep, docker isn't natively supported and it is a pain point we Mac users are stuck with.

If and when I run into performance issues with docker on mac, I build a Vagrant box and run docker in there; giving me better control of the performance controls. However, with using the more modern Docker Desktop I find myself doing this less and less these days.

Upgrading to a newer Mac with more ram/cpu is a solution of sorts too :D

Deets:

  • mac: 10.13.6
  • docker desktop: 2.0.0.0-mac81 (6vCPU|4GB Ram|2GB Swap)
  • docker engine: 18.09.0
  • docker compose: 1.23.2
  • docker machine: 0.16

Collapse
 
room_js profile image
JavaScript Room

Thanks for your feedback! That's sad that you need to come up with workarounds if you're a Mac user indeed... I understand now why some DevOps folks choose Linux :) Didn't consider running Vagrant so far but who knows where I will end up :)

Collapse
 
moopet profile image
Ben Sinclair

When I work from home, I sync my work with a Linux box and use that instead.

Collapse
 
room_js profile image
JavaScript Room

Hm, interesting... Do you do this synchronization by Docker Sync?

Collapse
 
moopet profile image
Ben Sinclair

no, I just rsync my static files and databases from time to time, the rest is all in git.

Thread Thread
 
room_js profile image
JavaScript Room

Nice. I see that Docker Sync is also might be using rsync under the hood, as they say in the description.

Collapse
 
leandronascimento profile image
Leandro Nascimento

Good question, I have the same problem. In my work I use Linux and it's very fast, but when running on my Mac it's very slow. I had to install locally to work well.

Collapse
 
room_js profile image
JavaScript Room • Edited

Yeah, super bad... And the answer is actually right above. Unfortunately, Mac OS doesn't support Docker natively...

Collapse
 
moopet profile image
Ben Sinclair

I use Internet Explorer as a tool to download a decent browser, and I use MacOS as a tool to connect to a useful development computer.

Collapse
 
artyfarty profile image
Dmitry Guzhov

You can use nfs mount solution. It is slightly harder to set up but it improves I/O performance.

Collapse
 
chico1992 profile image
chico1992

You could look into docker-sync.io/

Collapse
 
room_js profile image
JavaScript Room

Actually I've heard about it but didn't try yet. It's time I think! Thanks for sharing it!