Using DockerUI to Manage Docker Containers

Table of Contents

Introduction

Learn how to set up DockerUI on a Linux machine. DockerUI is a web interface for managing Docker containers. It simplifies the process of managing containers and images, and saves users from having to execute lines of commands to do small jobs.

Requirements

  • Ubuntu 14.04
  • Docker installed and running
  • Basic knowledge of Docker usage and commands

Installing DockerUI

To install DockerUI, pull the DockerUI image from Docker Hub and run it inside a container with the following command:

sudo docker run -d -p 9000:9000 --name dockerui --privileged -v /var/run/docker.sock:/var/run/docker.sock kevan/dockerui

In the above command, the default port of the DockerUI web application server is 9000. You can map DockerUI to a different port by using the -p flag.

After running the above command, check to see if the DockerUI container is running with the command:

sudo docker ps -a

You should see the dockerui container listed in the output.

Accessing DockerUI

After starting the DockerUI container, you can use the DockerUI interface to easily start, stop, remove containers, and perform many other Docker tasks.

To do this, go to a web browser and visit the URL http://yourdomain.com:9000. If your server is behind a firewall, you may need to allow access to the DockerUI port 9000 before you continue.

You should see the DockerUI web interface:

DockerUI web interface

Create a Container

To create a container, click the Images tab.

DockerUI - Images

Click the image ID of the image you want to launch a container from. In this case we will launch a container from the Ubuntu image.

Docker UI - Select an Image

On the next page click Start Container.

DockerUI - Start Container

In the pop-up window which appears, fill out any container options you want to set.

DockerUI - Container Options

When you have filled out your chosen container options, scroll down and click Create to launch the container.

DockerUI - Create

You will be returned to the page, which will refresh with a prompt about the new container which was just created. If you want to rename the new container, simply click Rename.

DockerUI - Rename

Start, Stop, Restart, Kill, Pause, Unpause, or Remove a Container

There are a number of actions you can perform on containers from the Containers tab. Tick the box to select the container you want to work with, then click Actions.

DockerUI - Select Container

Click on the action you want to perform.

DockerUI - Actions

Add or Remove a Network

To add or remove Docker networks, click the Networks tab.

DockerUI - Networks

To remove a network, tick the box to select the network, then click Actions.

DockerUI - Networks - Actions

Click Remove to remove the network.

DockerUI - Networks - Remove

To add a network, scroll down and fill out the information for the network you want to create, then click Create Network.

DockerUI - Create Network

Show Containers

The Containers tab lists all of your containers. The Containers Network tab provides a visual perspective of your containers.

DockerUI - Containers Network

Add or Remove a Volume

You can add and remove volumes from the Volumes tab. To remove a volume, tick the box to select it, then click Actions.

DockerUI - Volumes - Actions

To remove the volume, click Remove.

DockerUI - Volumes - Remove

To add a new volume, scroll down and fill out the Name and Driver field for the volume you want to add, then click Create Volume.

DockerUI - Volumes - Create

Content provided by 1&1

Comments

Tags: Docker / Containers