Welcome to TUNEIT
Hi everyone, Today I am going to deploy WordPress in Docker Swarm, behind Traefik
WordPress is open source software you can use to create a beautiful website, blog, or app
Please Subscribe to my channel to get updates when ever I upload new video, Lets Start... 
Login to Adminer, web database management tool using MariaDB server details
Create "mywordpress" database to use it with WordPress Stack
Check created database in adminer web UI
Go to "/opt" directory to create a folder for wordpress configuration
List files and directories in "opt"
Create a wordpress folder in "/opt", sudo mkdir -p wordpress
Go to wordpress folder, cd wordpress
List files and directories in "wordpress"
Create a wordpress configuration file, wordpress.yml
Copy and paste code in wordpress.yml file
I named it as "wordpress", it should match the service name in Traefik labels.
wordpree service depends on "maindb" (you should mention database stack name)
Use docker secrets for db host, db user, db name and mysql db password (It would be good to use docker secrets)
Under environment, mention mariadb host name, db user, db name and db passowrd secret variables
Docker overlay network (I named it as proxy)
Target node for wordpress service
Make sure the "wordpress" service name should match the name under Traefik labels section
Secrets, volume and network mappings at the end
Go to "/mnt" folder; list files and directories
Create a "wordpress" to map "/var/www/html/wp-content" folder of wp docker container for data high availability
Provide appropriate permissions for "wordpress" folder
Back again to "/opt" folder
Go to wordpress configuration file folder in "/opt"
List the files, make sure you have secret files and configuration file exists
Deploy wordpress stack using "docker stack deploy --compose-file wordpress.yml wordpress"
Check stack status using "docker stack ps wordpress"
Check service logs using "docker service logs wordpress_wordpress"
Open any browser and type the url of the wordpress stack (you should have DNS entry for the url in order to access it)
Check the certificate for wordpress site generated by Letsencrypt
Complete WordPress installation by providing site name, admin user and password
Log on to newly created WordPress site
Check WordPress dashboard
Go to Appearance-->Themes
Check the site with twenty twenty theme  
