Yeoman inside a docker container, with NPM packages installed into a non-root container.
620
This dockerfile builds a container with yeoman, generator-gulp-angular. I wrote this dockerfile because yeoman does not run as the root, and default docker containers run executables as root. This means that if you spin up a docker container and then try to run yeoman, it will fail.

yeoman-docker folder in this project's root:cd ~/my-repository/yeoman-docker
Replace my-repository with project's root. This folder should contain a file named dockerfile.
docker build .
The output of this command should look like this. 5. Once the docker image has built, run it:
docker run -dit my-image-hash
Replace my-image-hash with the unique identifier that docker gave to your image after building it e.g. fa817ac6674d.

3000 and 3001 are exposed. Port 3000 is where browser sync serves the site, and port 3001 is where it serves its own control panel. To keep things simple, you might want to map the port on the docker container to the same port number in Kitematic, i.e. port 3000 on the docker container maps to the IP address and port 192.168.99.100:3000 in Kitematic, and port 3001 maps to 192.168.99.100:3001. However, if those ports are already mapped to another application, such as a MongoDB server or docker container, you can map them to whatever available ports you have.

gulp serve

This is not a full-fledged project with semantic versioning. However, I might add the following features later if it is convenient for me:
npm install && bower install on container startup as yeoman user, before dropping to a shell.If you take the time to add these features, just send me a PR and I’ll merge them in!
Content type
Image
Digest
Size
204.3 MB
Last updated
over 10 years ago
docker pull designbyajay/dockerized-yeoman