...
The snippet above should be saved as a simple text file called Dockerfile. To build an image from it, I would recommend putting it in a dedicated folder, e.g.:
Code Block | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||
mkdir ~/docker/myproject mv Dockerfile ~/docker/myproject/Dockerfile |
Then change working directory to the newly created folder and build the image:
Code Block | ||||||||
---|---|---|---|---|---|---|---|---|
| ||||||||
cd ~/docker/myproject
docker build -t <image_name> . |
3 -
Info |
---|
Related articles
...