Most WordPress users have a set of tasks they do with every site they deploy. There’s actually an easier and faster way to go about this though using the excellent BackupBuddy plugin. I picked up this tip from Nathan Ingram at WordCamp Birmingham. Here’s how it works:
Getting Started
First we need to create our default installation. Add all the plugins you normally use as well as any themes that you’d like to include. Enter any activation codes for plugins like Akismet or Gravity Forms. Delete any content, posts-pages-links, that you don’t want. I also remove the default widgets that get added to the sidebar automatically. If you’d like suggestions on what to do when setting up WordPress, you can ready my list of what I do after installing WordPress here.
If you don’t already own it, you’ll need to purchase BackupBuddy and install it. Once it’s activated, you’ll have a new menu on the left in your WordPress control panel labeled “BackupBuddy.” Click on it and then select “settings.” You’ll need to create a password for your backup so you can import it later. Do that at the top of the settings page.
Create A Backup
To create your backup, go to BackupBuddy and select “Backup.” Just click the “Complete Backup” button and the plugin will do it’s thing. You don’t have to remain on that screen for the backup to function. While it’s backing up, I almost always get a warning that the archive hasn’t increased in size, but it always works out in the end. Once the upload is finished, you’re given a link to download the archive. Click it and download your backup.
Next click the menu item labeled “Migrate, Restore.” Here you’ll be able to download the tool that imports your backup called “ImportBuddy.” Once both ImportBuddy and your backup archive are downloaded, you’re ready made WordPress site is ready.
Rolling Out A New Site
Now when you need to put up a new WordPress site, here’s what you’ll need to do. Create a new database for your WordPress site or have the credentials ready if you’re sharing one. Upload the backup archive and ImportBuddy via FTP to the new server. Next, go to your site’s URL in a web browser with /importbuddy.php added to the end. Follow the “wizard” there to extract your ready made site into its new home.
Once it’s finished, just delete the installation files and you’re finished. In the time it takes you to prepare one site for development, you’ve created a reusable template to save you time on each one in the future. And you’ve picked up an amazing tool for keeping your site backed up automatically.
So that’s it. If you’ve discovered any extra uses for BackupBuddy, share them with us in the comments.
Gabriel July 10, 2014
Hi Bill
Your post talks about deployment when you are rolling out a new site from development to production. However, what about a site that already exist?
I mean I have my development environment dev.example.com and my production environment http://www.example.com both sites are identical but dev.example.com has robots.txt file to stop google to crawl it.
I did some changes creating new pages, add some plugins and change some CSS classes on my dev.example.com site. I would like to deploy those changes on my production environment without having to go inside my cPanel or deleting the http://www.example.com site and replace it with a new copy of dev.example.com
Can I achieve this using backupBuddy? if not do you know how could I achieve this?
Looking forward to hear from you
Bill Robbins July 11, 2014
Hey Gabriel,
Great question there. That’s one of the reasons that I host with WP Engine. They add a button in the WordPress dashboard that lets you create a staging site at will. That way you can test out new plugins or themes before committing them to the main site. You can even copy the staging site to the main one which makes large-scale changes easier to set up on existing sites.
You could achieve the same thing with Backup Buddy. The main downside is it will take a few minutes each time you make this transition during which your site will be down. How long exactly will depend on how large the site is, but 5 to 15 minutes is probably about right.
Hope that helps out,
Bill