Skip to content
This repository has been archived by the owner on May 25, 2022. It is now read-only.

Publish as Docker container #83

Open
stevenrombauts opened this issue Aug 16, 2016 · 9 comments
Open

Publish as Docker container #83

stevenrombauts opened this issue Aug 16, 2016 · 9 comments
Milestone

Comments

@stevenrombauts
Copy link
Member

stevenrombauts commented Aug 16, 2016

See if it possible to publish the box as a Docker container too:

  • Add a Dockerfile with instructions to build an image from Puppet
  • Make sure the container automatically mounts the www and Projects directory

Links:

@stevenrombauts stevenrombauts added this to the v1.4.5 milestone Aug 16, 2016
@stevenrombauts stevenrombauts modified the milestones: v1.5.0, 1.6 Nov 2, 2017
@miljan-aleksic
Copy link

I have recently tried Docker and this is my experience:

  • It is definitely the way to go, the modularity and flexibility are simply awesome.
  • There are speed issues when syncing the host and the container on MacOS. The solutions so far are not ideal and would require each one to find what works best.
  • If there is no sync involved, the speed is native, making it a perfect solution for creating fresh and scoped environments for testing, demonstrating, etc.

So far the best practice seems to extend other images, eliminating the need to use puppet or similar. For example, there is an official Joomla image which could be extended adding the Joomlatools Console. Even better the final image could just get what it needs from other ones or create temporal build images and keep the final image size small and free of build dependencies.

For my dev needs, I created such image and now working on an entrypoint script that would install Joomla and the demo content during the container creation, most likely with some variables to choose the configuration. This approach differs from the Vagrant Box as each container would hold only one Joomla Installation. Although would be possible to hold more, I think the single approach is more convenient.

All this was done in the last two days, me having quite a little experience administrating systems. I am excited to see what the Joomlatools team can do with it.

@stevenrombauts
Copy link
Member Author

Hi @miljan-aleksic, thanks for sharing your experiences with Docker. We agree that Docker is a great fit for our box and are exploring ways to use it. We don't want to drop Vagrant at once, a lot of people - including ourself - make heavy use of it right now in our daily workflow.

We'll probably start from a single big container, built from this Puppet repository which will basically be the same as the Vagrant box, and then start taking pieces out into separate containers so they can be interchangeable (with other technologies, versions and setups).

@miljan-aleksic
Copy link

That sounds good anyway :)

@stevenrombauts
Copy link
Member Author

@miljan-aleksic Would you mind elaborating on the issue you mentioned about syncing?

There are speed issues when syncing the host and the container on MacOS.

Does this problem render it unusable, or is just a bit slower from time to time? Pretty much every report we receive about Vagrant not working has to do with file syncing, and is one of the main reasons we are so interested in Docker (to get rid of such problems). Thanks for any info!

@miljan-aleksic
Copy link

The syncing it is a big known problem for Docker MacOS users. A simple manual 3MB extension installation takes a minute, even navigation slows down. It depends on the use case it can be a real pain.

A solution that worked for me was docker-sync. It's Ruby based, though... Once installed, the setting on the docker-compose.yml is quite simple.

@oligriffiths
Copy link

@stevenrombauts FYI, one of the major issues with file syncing is modifying files within a container during runtime that are NOT mounted, docker has to do some magic under the hood to make this work, and it's slow AF. The advised practice is to MOUNT any files/directories that the container will write to whilst running, this massively increases performance.

@stevenrombauts
Copy link
Member Author

@oligriffiths Thanks, that explains it. I was blindly assuming we were talking about the same thing. osxfs is what we're interested then, I guess.

@miljan-aleksic
Copy link

@stevenrombauts, I have shared a working example on a gist in the case can be useful.

@stevenrombauts
Copy link
Member Author

@miljan-aleksic That's awesome! Thanks!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants