March 31, 2020

Docker Notes

Run container in back ground with port forwarding:

#Remember to change local ip address and root password
sudo docker run -d -p 10.0.0.1:5555:22 --name ubuntu_sshd rastasheep/ubuntu-sshd:latest
sudo docker exec ubuntu_sshd /bin/sh -c "echo 'root:root' |chpasswd"

#5555:22 > host port:docker port
#Use Docker Start instead after img built

No comments:

Post a Comment