We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent d453b11 commit 00fa3d3Copy full SHA for 00fa3d3
Working-With-Volumes/README.md
@@ -0,0 +1,27 @@
1
+# UNDERSTANDING VOLUMES:
2
+
3
+To make the storage persistent in docker.
4
5
6
7
+* docker run -it --name busybox_1 -v /data busybox
8
9
+ // -v is used to add the volume
10
11
+* cd data
12
+* ls
13
+* touch test.txt
14
+* exit
15
+* docker run -t --name busybox_2 busybox
16
17
+* //Even though the image is of same image, the file is not being displayed
18
19
+* docker rm busybox_2
20
+* docker run -it --name busybox_2 --volume-from busybox_1 busybox
21
22
23
+ //Now the file is displayed inside the data folder.
24
25
26
+This is how persistent storage is created in the docker. So 2 APIs in two container communicating with each other use volumes to share the data.
27
0 commit comments