I’m done with LocalWP

I hate to say it, but I am abandoning Local WP (formerly by Flywheel). I used it the last couple of years, but I can’t do it anymore. I’m done.

Why? #

One big reason: databases. It is a huge pain in the neck importing databases into Local. I don’t have to do it very often, but every time I do it drives me nuts. Database imports have required nasty hacks for at least four years, so I don’t expect it to be fixed anytime soon.

It also seems like the focus of the app has changed. It used to be a great tool for developing WordPress sites locally, now it seems more like a great integration for its parent company, WPEngine. I love WPEngine as a platform, but many of my clients use other WordPress hosts, and Local simply isn’t the best option for sites that aren’t using WPEngine. Even for WPEngine sites, the connector utility is sketchy at best. It’s great when it works, awful when it doesn’t.

What do you use instead? #

I’m back to my old Docker Compose setup, which I made a video about several years ago. I have a boilerplate docker-compose template that I use in every WordPress site, and this allows me to create and destroy my local servers with very simple commands:

# firing up the server
docker-compose up

# shutting down the server
docker-compose stop

# destroying the server
docker-compose rm

In case you’re curious, here’s what my typical docker compose file looks like:

version: '2'

image: mysql:5.6
# this line automatically imports .sql files
# all I do is drop them into a /db folder
# and Docker does the rest!
- ./db:/docker-entrypoint-initdb.d
- ./db/conf:/etc/mysql/conf.d
restart: always
- "3306:3306"
MYSQL_USER: wordpress

# I usually leave PHP MyAdmin disabled unless I need it
# myadmin:
# image: phpmyadmin/phpmyadmin
# ports:
# - "8888:80"
# depends_on:
# - mysql
# restart: always
# links:
# - mysql:db
# environment:
# MYSQL_USERNAME: wordpress
# MYSQL_PASSWORD: wordpress

- mysql
image: wordpress:php7.3
- mysql:mysql
- ./:/var/www/html
# I use a unique port number for each client
# (you only change the first number, "8000")
- 8000:80
restart: always

As long as you have Docker installed and running, you can place this file inside your root directory (name it docker-compose.yml), run docker-compose up and Docker will do the rest. It will automatically spin up a new server and database, and import any SQL files that it finds in the /db folder. It works like magic, no more frustrations with Local.

If Docker is so great, why did I stop using Docker? #

Partially because Local was new and shiny, and everyone else was using it. It’s a pretty app, and I like to use pretty apps.

I also tried it because Docker can be slow on Macs. Locals wasn’t really much better—they probably use similar tech behind the hood—but I hoped Locals would be better on Macs.

Now I use a Linux computer full time, and Docker works like a dream on Linux, so there’s really no downside to switching back to Docker.

← Home

  • Adds new internal link
  • Adds new article about Locals