How to Migrate a Website
Introduction
In this guide you'll backup a website and migrate it to a new destination on the same server. For example, you'll backup a production website and migrate it to a development website.
Prerequisites
To follow this article, you will need:
- WordOps installed on your server
- wo-scripts installed on your server
Step 1 — Backing up the source website
Follow the How to Manually Backup the Server guide to create the source backup.
Step 2 — Creating the destination website
Follow the How to Create a New Website to create a new website or use one that's already made on the same server.
Step 3 — Migrating the source website to the destination
Next, run the following command, swapping out the domains out and replacing 202208221423
with the backup located in /opt/backups/superrad.dev/
.
/scripts/wo-scripts/wo-migrate.sh source.com destination.com 202208221423
danger
Running wo-migrate.sh
will delete everything in the destination website.