Skip to main content

Docker Commands

General CMD


Show list of dockers:

docker ps

copy CMD

cp <source file.ext> <new file.ext>

Host Web Server

python3 -m http.server 1337

Bash into Docker container

docker exec -it <container name/id> bash

accesed via SSH allows to run cmds as the container


Make Dockerfile

https://stackoverflow.com/questions/45152426/create-docker-compose-file-from-dockerfile


Enable SSH and Root

cd sr