Загрузка...

Docker volume explained

VolumesBind volume and Named volume
Containers are ephermal that means , if we delete the container files indiside of that container will delete too , to resolve this issue we need to know two different types of volumes in docker.
Bind volumesBind volumes maps folder inside your laptop to folder inside container.It's like two way mirror , that means whatever the changes you do on the folder that is there in your laptop that will reflect on folder on the container.useful for source , so container folder can get fresh code

Named volume A Named Volume is a storage area managed entirely by Docker.You don't know exactly where the files are on your laptop.

You just give the volume a name like db_data.Here docker will create a storage internally , then it assigins that storage element to the container , even if container deletes , still you can get the storage, so you can attach that storage to new container.Highly used for database..

Видео Docker volume explained канала Hemant Patil
Яндекс.Метрика
Все заметки Новая заметка Страницу в заметки
Страницу в закладки Мои закладки
На информационно-развлекательном портале SALDA.WS применяются cookie-файлы. Нажимая кнопку Принять, вы подтверждаете свое согласие на их использование.
О CookiesНапомнить позжеПринять