- Enable the "Extras" Red Hat channel so you can install Docker ...
#subscription-manager repos --enable rhel-7-server-extras-rpms
- Make sure to enable the docker service...
# systemctl enable docker
- ... and that it can be run as the apache user (this may be dropped as the code matures)
# usermod -aG docker apache
- Deal with SElinux (this may be dropped as the code matures)
# echo "OPTIONS=--selinux-enabled -H tcp://0.0.0.0:2375 -H unix:///var/run/docker.sock" >> /etc/sysconfig/docker
- Finally, start the docker service
- Test that Docker is working (you should see a similar output as shown below):
# docker ps
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
- Obtain a valid Docker image (use busybox for a fairly small and fast download; I chose to use fedora/ssh for this)
- Create a new "Docker" Compute Resource and use "http://localhost:2375" for its URL
- The Test Connection button shows a spinner icon but no confirmation message is displayed to tell you whether things look ok or now
- To create a new container, click the Containers and New container menus, and select the Docker compute resource you created before
- Type fedora/ssh (case matters) in the search field and latest in the Tag field
- NOTE: for some reason, it wasn't until I manually started a container manually with
docker run --name myfedora -t fedora/ssh:latest
that this part of the process verified that fedora/ssh was a valid entry by showing a green check mark.
- Type a name for your container...
- Click the TTY checkbox...
- ...and your new container is ready to be started
- You can see your container by going to the All containers submenu under the Containers menu.
When I opened the console for my container I see the following message:
Could not load host key: /etc/ssh/ssh_host_ecdsa_key