Skip to content

MayadaMagdy24/Docker-lab1

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 

Repository files navigation

Docker-lab1

1- •Run the container hello-world Screenshot (775)

•Check the container status Screenshot (776)

•Start the stopped container Screenshot (778)

•Remove the container Screenshot (792)

•Remove the image Screenshot (780)

2- •Run container centos or ubuntu in an interactive mode •Run the following command in the container “echo docker ” •Open a bash shell in the container and touch a file named hello-docker •Stop the container and remove it. Write your comment about the file hello-docker (file removed ) •Remove all stopped containers

Screenshot (783)

3- •Run a container httpd with name apache and attach a volume to the container •Volume for containing static html file •Remove the container Screenshot (784)

•Run a new container with the following: •Attach the volume that was attached to the previous container •Map port 80 to port 9898 on you host machine Screenshot (786)

•Access the html files from your browser Screenshot (772)

4- •Run the image httpd again without attaching any volumes Screenshot (798)

•Add html static files to the container and make sure they are accessible Screenshot (802)

•Commit the container with image name my apache Screenshot (800)

5- •Create a volume calledmysql_data, then deploy a MySQL database calledapp-database. Use the mysqllatestimage, and use the-eflag to setMYSQL_ROOT_PASSWORDtoP4sSw0rd0!.Mount themysql_datavolume to/var/lib/mysql. The container should run in the background. Screenshot (774)

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published