DevOps Classroom notes 11/Oct/2024

Docker Images, Containers and volumes


ARG and ENV

  • ARG can be used as a parameter while building images Refer Here
  • ENV can be used as a parameter while running containers Refer Here

.dockerignore


Lets run a postgres database inside a container

  • Lets create a postgres database with password, user, database and volume mounting (refer classroom video for commands)
docker run --name lib-db -d -e 'POSTGRES_PASSWORD=password' -e 'POSTGRES_USER=lt' \
> -e 'POSTGRES_DB=library' -v lib-vol:/var/lib/postgresql/data postgres:17

Exercise

  • Run mongodb, mysql and microsoftsqlserver with volumes in a contianer
Published
Categorized as Uncategorized Tagged

By continuous learner

devops & cloud enthusiastic learner

Leave a ReplyCancel reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Please turn AdBlock off
Social Media Icons Powered by Acurax Web Design Company

Discover more from Direct DevOps from Quality Thought

Subscribe now to keep reading and get access to the full archive.

Continue reading

Exit mobile version
%%footer%%