Today I would like you to show for me the easiest and fastest way how to make WordPress work for you on your local machine in almost a few simple steps. We gonna use Docker hub and it will take 10 minutes.
Download Mac stable installation on official Docker hub domain here:
Run installation from the
dmg file you have downloaded.
Approve access and privileged access that Docker Desktop will ask for.
Create a directory for the website for example on Desktop, so go to
Desktop, create directory
wpwebsite and enter into it using these commands one by one.
cd Desktop mkdir wpwebsite cd wpwebsite
docker-compose.yml you will find hereunder file into
wpwebsite directory. It's an image for WordPress docker container installation that will set up all needed, like WordPress directory structure and MariaDB database as well.
Now type into terminal this simple command.
You are ready to go through WordPress installation on your local machine. Go into the browser and type this
Pass all this installation and now you are ready to login to your local WordPress installation. You can check it as well on Docker Desktop Dashboard clicking on a tiny icon on your top panel.
And check it anytime how DB and website are running and stop or delete it anytime.
When you want to access your local WordPress installation next time just type
localhost:2000, so whole url to start installation will be like this.
And yeah, don't forget to copy some theme into
wpwebsite/wp-content/themes to see something real in your browser, cos this standard installation doesn't have any.
Hope you enjoyed this little WordPress installation adventure and found it interesting and now you are ready to go with a local WordPress theme or plugin development.
If you have questions or enjoyed this article, please feel free to comment or message me here or share if you think others might be interested too.
Thanks to Isaac Ibbott for the cover image from Unsplash.