Overview

Docker configuration is done in the YML files, where we should describe what we want and how that should be linked in regards to:

Storage

Network

Ports

Let's start by downloading and installing MySQL database which has been dockerized.

MySQL Configuration

Once we have docker installed, we can search and install any image we want:

By default the “hello-world” image is always installed and can be run as follows:

Now we can install the mysql image as follows:

We can check installed images of course and see how much space they occupy:

We can see now, that I have installed 2 mysqls, we can initiate a new container for mysql image as follows:

We can check the logs of the installation as follows:

Finally, we can connect to the mysql, by running the mysql command from the docker:

Here is example of such configuration of Mongo database container:

In case of changes, you have to restart the container is follows: