High Score Labs News • Aug 12, 2021
Switching hosting services is no small feat. Add the clumsy upgrades that come with cloud platform hosting to the mix, and you’ve got a near-impossible task on your hands. Without guidance, it’s all too easy to get lost amidst it all. This article provides a checklist to ease your process of migrating your Drupal 8 site to Acquia cloud platform hosting.
The first thing you want to check off your list is also the most basic – your codebase. Ensure it conforms to Drupal best practices such as proper version control use, dependency management, etc. which shouldn’t be a problem considering you’re running a Drupal 8 site.
Next, prepare your codebase for the kind of hosting service you’re migrating to – Acquia Cloud Platform in this case. Doing this allows you to take full advantage of the platform’s functionalities such as the Acquia connector module which enables your site to send metrics and other data to Acquia subscriptions. You also get access to insights and continuous uptime optimizing for Acquia.
Once you check the above off your list, you can prepare your code for deployment by placing it in Acquia’s repository. Here, you have a final opportunity to evaluate your CI/CD pipeline. Further, you have a vast array of commands to plug into your code from Acquia’s Build and Launch Tool (BLT).
With the codebase nailed down, it’s time to start moving your database over. For this step, I’d recommend Drush CLI Tool. It’s user-friendly and supports backing up and restoring. You’ll need to download a few aliases to be able to use Drush, however. Thankfully, these aliases are provided in the Credentials Tab in Acquia Account Settings. The aliases will be dropped into the Drush directory within your codebase.
Simply create a database backup using the code below and transfer it to the Acquia servers.
Next, transfer your database backup to the Acquia server;
Afterward, go ahead and import your database to the Acquia site;
The next aspect of your Drupal 8 site to be migrated are your files. The sync can be easily executed using the Drush rsynccommand. Here’s the command to use:
Testing and Launch
Having copied every aspect of your site from your old server, you should then proceed to extensively test the website in Acquia’s pre-production environment to ensure that everything is copied appropriately. If issues come up, go over the above steps to see what you may have done wrong and correct it. If everything works and the site is stable, then it’s launch time.
It’s always good to perform one last migration check before decommissioning your old servers. One can never be too careful, right? Finally, once your migration is complete, flip your DNS and decommission your old servers. Congratulations on successfully migrating your Drupal 8 site to Acquia Cloud Platform Hosting with little to no stress at all.