Closed 0o-de-lally closed 9 years ago
dandielden/meteor
is built on the buildpack-deps:jessie
image, which weighs in at a staggering 677.5MB, while ubuntu:trusty
comes out at a large, but manageable 188MB. Debian used to be substantially smaller, but comes out at debian:jessie
125MB. The trouble with the debian distribution is that its nodejs package has historically been very out of date.
The real problem with the bloat of this package is the inclusion of the prerequisites for phantomjs. That pushes it way up. (748.6MB)
I keep meaning to make a minimal tag which doesn't include it so that people who don't need it will have a more reasonably-sized image.
Since you're asking, I'll get a more minimal one up later today.
Heh; never mind. The minimal build (without phantomjs) is 717MB. That's hardly worth maintaining a separate fork. Meteor itself is reasonably hefty, with a few hundred MB. Perhaps some of that could be shaved off, but it doesn't seem to be a worthy effort to do so.
Hi there thanks for the explanation. Pardon my ignorance, but how much of the OS does meteor really need? Could there be an even leaner option than debian?
Comparison: danieldent/meteor latest 593a03f32942 5 days ago 998.6 MB ulexus/meteor latest 2627f5f5b7b9 9 weeks ago 748.6 MB
I have attempted running it on Alpine in the past without success. I don't recall the problem, exactly, but meteor itself wouldn't run.
The problem is that Meteor is really a bunch of scripts; there isn't one true Meteor binary which just needs some libraries to work. Meteor expects to have available to it a whole bunch of OS utilities, as well as its dependent packages. One could go through and pick and choose just those things which it uses, but that would take a very long time, and it would be extremely brittle.
Bottom line, unlike the grand new wave of golang programs, Meteor expects to be run on an OS, with all the luxuries that affords.
Got it, thanks. Can you give us some more clarity in the read me about how to link to a running mongo instance. May sound basic, but it wasn't obvious when I first tried it with env variables. Thanks again!
What part? I'm happy to update the documentation for clarity, or I'll be even happier to accept a pull request, but I'm usure what part is unclear.
There are different env variables for mongo. So just need examples for using each. I haven't yet managed to get my app to run with this docker image, while a mongo instance runs on the same host.
As an update: the size of the image is now down to under 280MB. The Meteor tool is downloaded at runtime (only if needed). If you supply a BUNDLE_DIR
or BUNDLE_URL
, then the Meteor tool is not needed and not downloaded. This also significantly speeds up the container start processes.
I really like your git workflow. But it seems that starting from Ubuntu is too much bloat. Is there a reason for this? Another set up is suggested here: https://registry.hub.docker.com/u/danieldent/meteor/