What is Nostr?
captjack / captjack 🏴‍☠️✨💜
npub1te0…jgwp
2024-09-28 14:10:29

captjack on Nostr: *** mounting host directory to container directly *** - any edit visible in both. ...

*** mounting host directory to container directly *** - any edit visible in both. -🇻 flag
$ docker run -it --rm -v /home/user1/hostpath:/home/cont_path ubuntu /bin/bash
root@e8439d98c635:/#
#linuxstr #docker #techtip *** must do at start or else hav2 stop - do - restart
very useful if using hot swap SATA SSD mSATA disks without reboot host system.
Let’s break down this command:
-i -t (or -it) enables interactive access to the container
–rm removes the container upon exit to free system resources (CPU, memory)
/path/on/host is the path of the directory on the host machine that we want to mount
/path/in/container is the desired path within the container where the directory will be accessible
image_name is the name or ID of the Docker image we want to run
/bin/bash provides a Bash shell within the container



Author Public Key
npub1te0uzs6vj29umjaxlqqct82j8q6ppyefrxq06dhr8d6pvwfatgkqjmjgwp