10 ms·
Is IO still going to be horrible here? Docker on a linux VM, with all code on the linux VM, is significantly faster than Docker for Mac. Generally just because
by phamilton 5y ago
Is IO still going to be horrible here?
Docker on a linux VM, with all code on the linux VM, is significantly faster than Docker for Mac. Generally just because of IO.
- tgv 5y agoIO in Docker has improved greatly, some 6 months or so ago.
- krono 5y agoThe increasing amount of unexplainable hangs and crashes has since offset any of those improvements many times over.
- deleted 5y ago[deleted]
- rubyist5eva 5y agoI used it last week...it's still really bad. Running IO heavy tests taking literally 100% more time for me. I'm just running openSUSE MicroOS with podman for my container workloads now, it's been rock solid.
- zapita 5y agoAre you talking about IO on Docker for Mac when mounting files from the Mac host to the container? In that case, for an apples-to-apples comparison you would have to run your microOS+podman setup inside a VM on MacOS, then mount files from the host into that. I doubt the IO performance will be any better.
- rovr138 5y agoThe whole point of the thread is about how running Docker on a Linux VM is faster than docker for Mac.
- alexellisuk 5y agoIt's going to be pretty bad because it's using SSHFS - but your mileage may vary. For Docker Desktop, hopefully Justin Cormack will stop by and answer.
- hutrdvnj 5y agoSSHFS is about the worst FS in existence. I would only recommend it for a temporary file transfer here and there, but it's nowhere near stable enough to use it like a regular FS.
- kiririn 5y agorclone mount does a better job - it’s designed to handle high latency and flaky http apis, so the sftp backend with none of these limitations is a joy to use. Night and day compared to sshfs
- TimTheTinker 5y agoThis is why I run my dev environment in an Ubuntu VM on Parallels Pro.
- dkarras 5y agoI use vagrant boxes (virtualbox) with nfs shares, works well. I'd still do it if I was on linux to be honest. My VMs are provisioned in a way that they have everything installed for the particular project and they are "stateless" in a way that I can and sometimes do reset them to their post-provision state (as virtualbox / vagrant supports snapshots) and my experience with the project stays the same. They are meant to be the perfect environment for a given project and nothing else. The "mutable" stuff is just mounted as nfs shares from my host machine.
- regularfry 5y agoI would do, but corporate VPN management clobbers the routing table and breaks it.
- TimTheTinker 5y agoParallels' "Shared Network" doesn't suffer from this problem.
- regularfry 5y agoAny idea how?
- deergomoo 5y agoJust as a heads up, I was finding that with NFS shares configured, my MacBook would never sleep if connected to power. Took me ages to work out why I kept sitting down at my desk to find a very hot, closed laptop with the fans screaming. Turned out to be NFS, though not sure if it was a bug or intended behaviour.
- 5y ago
- beefbroccoli 5y agoIf you want to remove a lot of unnecessary pain in your life, completely abandon the idea of mounting a host FS within a guest VM. Doubly so if they're different OS's/FS's and triply so if this a development VM.
- phamilton 5y agoOh, I have. My setup is now Remote VS Code to a Linux NUC that sits on my desk. All code lives on the NUC and all tests run on the NUC, but I can use my MacBook Pro as I move around the house, work outside, etc. It's pretty seamless, I'm impressed.
- amatecha 5y agoOh what… by "Remote VS Code" are you referring to this? https://code.visualstudio.com/docs/remote/remote-overview https://code.visualstudio.com/docs/remote/remote-overview Seems very handy indeed!
- phamilton 5y agoYeah, the VSCode UI runs on my Mac, but it runs a vscode remote server on my NUC. Debugger, tests, etc. all run on my remote machine. I originally did this in a Linux VM, but got tired of the battery hit that running a VM 24/7 has.
- amatecha 5y agoNeato, that's pretty awesome! Can keep your main machine freed up to deal with actual editing and other usage, while the remote server does all the "heavy lifting". Thanks for the info!
- soziawa 5y agoI have had a similar setup with a remote server and a MacBook Air. If internet on trains were a bit more stable it would have been the perfect setup.
- 5y ago
- da39a3ee 5y agoWith VSCode you can develop on mac with your code in a docker volume, so no need for the code syncing that you're referring to.
- TimTheTinker 5y agoEven without code syncing, running more than 5 or so Docker containers can eat up a lot of RAM and even more CPU. It's just not worth it - put them all in a Linux VM.
- da39a3ee 5y agoThey are in a linux VM! The only possible place a docker container can ever be on a Mac laptop is in a linux VM.
- TimTheTinker 5y agoRight, but it's not the same VM for all docker containers. And disk IO is synced, which eats up a lot of CPU.