InterviewSolution
Saved Bookmarks
| 1. |
Create a docker file and build a new image. Run the image and create a container. |
Answer»
--Build an image from the dockerfile, tag the image name as ‘mydocker’ docker build -t mydocker dockerFiles/ docker build --tag <containerName> <dockerfile location> Divya1@DIVYA:~ $docker images REPOSITORY TAG IMAGE ID CREATED SIZE mydocker latest aacc2e8eb26a 20 seconds ago 88.1MB Divya1@Divya:~ $docker run mydocker /home/divya Hello Divya Bye Divya
|
|