Docker/Dockerfiles: Difference between revisions
From charlesreid1
No edit summary |
No edit summary |
||
| Line 20: | Line 20: | ||
https://docs.docker.com/engine/reference/builder/#copy | https://docs.docker.com/engine/reference/builder/#copy | ||
[[Category:Docker]] | |||
Revision as of 07:54, 24 March 2017
The Dockerfile is where you define the commands that populate your docker container.
Crafting
The Philosophy
The idea is to have easy to start and easy to stop services that are stateless, and don't "expect" stuff. (Not sure I understand that exactly, but okay.)
Web app stack example: LAMP would implement Apache as one container, MySQL as another, and PHP as another (well, maybe A+P as one.)
Maybe one container for a cache, too.
Keep em clean, keep em modular.
Copy command
Copy command allows you to copy stuff from local host system into the docker image.
Add command works too, but copy less complicated.