Docker - TrippCC/Sys-265 GitHub Wiki

Setting up IP address: https://websiteforstudents.com/ubuntu-root-default-password-setting-root-password-on-ubuntu-16-04-18-04/

Changing hostname: https://linuxize.com/post/how-to-change-hostname-on-ubuntu-18-04/

adding user: useradd mason passwd mason usermod mason -G sudo

Installing Docker: Use steps 1-3 https://www.digitalocean.com/community/tutorials/how-to-install-and-use-docker-on-ubuntu-18-04

Check to see if it is running: systemctl status docker

Check if the named user can access docker version: run command: docker version if it says permission denied make sure that the named user is part of the docker group (this might require logging out and back in)

Running the docker hello-world application run command: docker run hello-world

Installing docker-compose:https://phoenixnap.com/kb/install-docker-compose-ubuntu run "docker-compose version" to get version

run command "docker run --rm archlinux:latest /bin/echo "HELLO SYS265"

to see list of downloaded images on docker-mason: docker images

version of kernals being used: cat /etc/lsb-release echo "current kernel is:$(uname-a)" docker run -it archlinux /bin/uname -a

run: docker run -d -P training/webapp python app.py use "docker ps" to see the if the image was pulled (make note of the port it is on)

go on mgmt01 and look up http://docker-mason:(use port number that you saw in last step)

use "docker stop (name of testapp)" to stop the test app use "docker ps" to see if it worked.

download Wordpress using: https://docs.docker.com/compose/wordpress when creating the file the spacing is very important, use tabs.

If you get an error about failing to setup IP tables restart docker (service docker restart) and try again