News for hackers. Stuff that matters.
Re:Running Docker on Apple Silicon M1 (Follow-Up) by globular-toast on Friday November 27, 2020 @10:58AM (#25229679)
> I would hope that most people's production images are being built & pushed to an image repository in CI, not from somebody's laptop.

That's not really the point. Cross-compilation is no problem these days, especially for targets like x86-64. The point is rather that devs will be running the code locally in a completely different environment to production which defeats the purpose of using Docker for development.

Re:Running Docker on Apple Silicon M1 (Follow-Up) by pashky on Friday November 27, 2020 @11:22AM (#25229947)
I keep hearing this mantra of "same environment". But is it really ever the same? One of my previous workplaces insisted on everyone having bloody openshift locally, so your dev env supposed to be closer to prod. Guess what, it still wasn't by a long stretch, yet it ate half of usable laptop's RAM and was slow like hell.

Most people quietly switched to docker-compose templates shared through private repos within a month for quick local runs and then tested end-to-end in dev cluster when it was mature enough.

What I'm saying here is that architecture mismatch is really just another variable, and purpose of docker locally nowadays is not to replicate prod. That is unachievable and the sooner one accepts it the better. Still it's the best way so far to keep DLL hell at bay.

Re:Running Docker on Apple Silicon M1 (Follow-Up) by jrrrr on Friday November 27, 2020 @11:22AM (#25229938)
It defeats _one_ of the purposes of using Docker for development.

I expect that the official M1-supporting Docker Desktop will eventually, given a dual-arch image, allow you to choose which architecture to use. (One would run natively, the other under emulation)

There are situations where I'd use this feature, but 90% of the time I'd be fine using arm images locally and deploying x64.

(I could also imagine this working the other way -- an x86 dev machine and an arm deployment target -- which I think to some degree is supported by Docker today)

Re:Running Docker on Apple Silicon M1 (Follow-Up) by markstos on Friday November 27, 2020 @12:25PM (#25230594)
At least on AWS, it's slightly cheaper to deploy ARM servers. Look for this problem to also get solved on the server side by more ARM servers being put into production.
Re:Running Docker on Apple Silicon M1 (Follow-Up) by klelatti on Friday November 27, 2020 @11:16AM (#25229872)
Isn't the point that the environment is very close (and the M1 may be a lot faster than a comparable machine) and that the CI will test the final code on x86 before deployment?
Re:Running Docker on Apple Silicon M1 (Follow-Up) by ashtonian on Saturday November 28, 2020 @08:30AM (#25237385)
It's not ever the same, that's what qa/staging is for. Paired with ci and good Integration tests it's still works. Simplicity in a local dev env is king.
Re:Running Docker on Apple Silicon M1 (Follow-Up) by pjmlp on Friday November 27, 2020 @11:23AM (#25229953)
That was already a bad reason to start using Docker anyway, instead of fixing the devenv, yet another workaround.

As Java/.NET dev having heterogeneity between environments was never an issue.