Docker Volumes Explained (PostgreSQL example)

preview_player
Показать описание
In this short video I discuss docker volumes and demonstrate how to use volumes with postgres instances. We will create a postgres docker container, create some tables, backup our volume, destroy the container and spin up a brand new container with our existing volume.

#POSTGRES
docker run -p 5432:5432 --name pg -e POSTGRES_PASSWORD=postgres postgres

#PGADMIN
docker run -e PGADMIN_DEFAULT_EMAIL="hussein” -e PGADMIN_DEFAULT_PASSWORD=“password” -p 5555:80 --name pgadmin dpage/pgadmin4

Enjoy

🏭 Software Architecture Videos

💾 Database Engineering Videos

🛰 Network Engineering Videos

🏰 Load Balancing and Proxies Videos

🐘 Postgres Videos

🚢Docker

🧮 Programming Pattern Videos

🛡 Web Security Videos

🦠 HTTP Videos

🐍 Python Videos

🔆 Javascript Videos

Support me on PayPal

Become a Patreon

Stay Awesome,
Hussein
Рекомендации по теме
Комментарии
Автор

This is a wonderful video! You inspire me to keep pushing!
A clever mnemonic (not my own) for remembering tar:
czvf = create ze vucking file
xzvf = xtract ze vucking file

matthewwiese
Автор

Whenever you start showing hands-on demo, you became a legend to me, you are genius on explaining things but hands-on demo make you super special. Keep up your good work.

sanyk
Автор

Let me tell you- when I looked this topic up and saw you had a video in the search results, I felt instant relief. Dare I say, excited

aubydauby
Автор

when ever I am looking for something and I see your video am excited that I have found what I am looking for

salmanmusa
Автор

This guy's a natural teacher - thank you for the content! Made my life much easier.

mattbillman
Автор

how to remember tar flags:

tar -xzf eXtract Ze Files.
tar -czf Compress Ze Files.

Ali_Alhajji
Автор

Exactly what I was looking for and perfectly explained, thanks a lot!

joaquinurruti
Автор

dude... when I'm searching for some topic video and I see one of yours... ;-)
I already like it first and then proceed to see the video... LOL!!!

IBITZEE
Автор

Hussein god bless u with this information

najisolayman
Автор

Thank you Hussein for your explanation, I tended to use docker volume for the exact same case you mentioned in 12:10

MrOmarlive
Автор

This guy is funny. No dull moment with him lol

okonkwo.ify
Автор

thanks Hussein, its so simple and clear .

islamsaied
Автор

That's exactly what I was looking for, Thanks a lot.

juansalcedo
Автор

Very well explained, & clear communication, - so many tech videos are created by people who are very difficult to understand. Thank you! :) ATB

Maefcent
Автор

Sweet, Succinct and straight to the point

osazemeusen
Автор

Great video! can you research more advanced topic? best way to work with postgres data migrations. When you have postgres db in one container and backend app on other container. Backend app on java (ktor or vertx or other lightweight backend framework even in pure netty)
1) What the best way to initialize initial database structure with all required extensions(ex timescaledb)
2) What the best way to migrate database data structure while your project evolving
Thanks!

rpzwkbw
Автор

Hi Hussein, you are better than uni professor. Thanks for the video. I am wondering if it is possible to attach this volume of data to more than one postgres container for load balancing?

ammadkhan
Автор

Error: Database is uninitialized and superuser password is not specified.
You must specify POSTGRES_PASSWORD to a non-empty value for the
superuser. For example, "-e POSTGRES_PASSWORD=password" on "docker run".

You may also use to allow all
connections without a password. This is *not* recommended.

See PostgreSQL documentation about "trust":

rahul_bali
Автор

Another fantastic informative vid... quick question, or better still a follow up vid request... how to extend this to concept to my NAS drive, i.e. NFS storage?

AbdullahKhan-hzyr
Автор

Good tutorial, but the PostgreSQL Docker container has changed, so you cannot easily follow along any more. You have to do stuff like add "--env POSTGRES_PASSWORD=password" to his command lines.

russellbateman