Episerver DXP Optimizely/Episerver

Download database + blobs from your Optimizely DXP project

With Optimizely DXP, we as developers do not have direct access to the production environment. If I want to get the database + blobs from the production environment to update my local dev environment - this is how it's done.

Export the database

The database export can be started from the self-service portal. You simply select the environment, the database, and for how long you want it stored.

Graphical user interface, text, application, email

After a few minutes/hours/days (hard to tell) your database export is ready for download.

Export the blobs

To export the blobs, one option is emailing Optimizely Support, asking for help. They will probably answer (quite fast) that they have saved the production blobs as a new blob container in the storage account for the integration environment, which we can access. But how do you download them all?

Using Azure Storage Explorer you may view, copy, delete and download. But there is no easy way (that I'm aware of) of downloading an entire blob container.

The new container (blobsfromprod) created by Optimizely Support.

Graphical user interface, application

Azure CLI to the rescue!

If you are not sure how to access the blobs, you can copy the connection string from the Azure Portal, where you should have access to the webapp for the integration environment.

Graphical user interface, application

Then use Azure CLI to batch download all blobs.

az storage blob download-batch 
  -s blobsfromprod 
  -d e:\blobs\project1 
  --connection-string [connection-string-copied-from-azure-portal]

An alternative method for downloading blobs

You could also use PowerShell as described by Epinova here.