MariaDB is a powerful database server used by millions of users out there. There are several ways to install MariaDB. Today I am going to build a MariaDB Server using Docker on top of a Debian 9 host. Docker is a powerful and lightweight virtualization technology to run applications in a container. I have written many tutorials about docker in this blog.
Steps to build a MariaDB Server using Docker
Step 1. Install Docker
Step 2. Start MariaDB Server Instance
Now, execute this command to start MariaDB instance on Docker.
docker run --name some-mariadb -e MYSQL_ROOT_PASSWORD=my-secret-pw -d mariadb:tag
Where some-mariadb is the name of your mariadb instance, my-secret-pw is your password for MySQL root user and tag is the tag specifying MySQL version you want.
docker run --name mariadb-server -e MYSQL_ROOT_PASSWORD=12345 -d mariadb:latest
At this point, our MariaDB instance should be running. You can start manage it and use it.