Docker
#Enter Shell within Container
docker exec -it CONTAINER sh
docker exec -it CONTAINER bash
#Docker Compose Profile
docker compose --profile stack-1 up -d
#Enumerate Running Containers
docker ps
#Create Network
docker network create NETWORKNAME
sudo docker network ls
#Removes offline containers, volumes, networks and images
docker system prune -a
#Remove Dangling Images
docker system prune
#List current images and inspect the current version of image
docker images
docker inspect <IMAGE ID>
#Display volume location
docker volume inspect volumeName
#Check public IP/Gateway
sudo docker exec CONTAINER wget http://ipecho.net/plain -O - -q ; echo
#move files into container
sudo docker cp '/home/ubuntu/madoka/madokamovies/madoka movie 3.mkv' sonarr:'/downloads/movies/Puella Magi Madoka Magica the Movie Part III Rebellion (2013)'
#transfer files to host over SSH
scp "Shutter.2004.1080p.BluRay.x265.hevc.10bit.AAC.5.1-HeVK.mkv" ubuntu@192.168.1.120:/home/ubuntu/shutter
#transfer directory to host over SSH
scp -r "Shutter" ubuntu@192.168.1.120:/home/ubuntu/shutter
Docker Volume Location:
/var/lib/docker/volumes/media-stack_torrent-downloads/_data
Last updated