Docker WordPress: How to Install WordPress on Docker Containers

In this docker tutorial we are going to learn how to install WordPress on Docker.

To run wordpress we need two docker containers. One for the MySQL Server instance and other one is for the wordpress instance with a link to the mysql container.

How to Catch Standard Error to a Variable in Bash

To store stderr into a variable we need to use command substitution.

But, by default, command substitution only catches the standard output(stdout). To capture stderr we need to use 2>&1 redirector.

Docker MySQL Containers: Learn How to Run MySQL on Docker

MySQL is the most commonly used open source relational database management system. In this tutorial we will learn how to run MySQL Containers on Docker Engine.

Docker MySQL Containers are very straight forward. Starting a new server instance is very simple.

Run Docker as non root user without sudo command

By default docker command need root permission because The docker daemon runs as the root user. So by default, either you need to be the root user or you have to run docker with the sudo command.

But, How do we run docker as non root without sudo command?

Solution to cannot connect to the docker daemon Error

There are two reasons you get the “cannot connect to the docker daemon” error message when try to run docker command.

One reason is docker service is not running. Another reason could be you are trying to run the docker command as non root user.