This section will cover how to create snapshots of remote environments and restore to remote environments as well as transferring snapshots to and from local environments ready for SilverStripe Platform.

Getting started

To access snapshots go to the SilverStripe Platform Dashboard and log in using your SilverStripe Platform account and click the ‘Snapshots’ tab.

Select your stack from the menu and select the ‘Snapshots’ option:

Deployment Snapshots Tab

All snapshot features expect the sspak format. To get started with this you’ll need to head over to Github and install sspak. Note that Windows users will also need ot install third party software as sspak does not natively support Windows.

Create a local snapshot

You can create different types of local snapshots including; database and assets, database only or assets only.

After installing sspak you can run one of the following commands to create a snapshot assuming /var/www/project1 is the public root. These should be ran as your web user. This is typically www-data on Debian and Ubuntu Linux, or the current user if you’re using Windows.

# Database & Assets
sspak save /var/www/project1 project1.sspak

# Database Only
sspak save /var/www/project1 project.sspak --mode db

# Assets Only
sspak save /var/www/project1 project.sspak --mode assets

Restore a snapshot to a local environment

This applies to snapshots that you or another team member has created and explains how to restore them to your local environment.

You should already have an sspak file which you’ve downloaded or created from another environment. You can run the following command to restore it to your environment. Again, we’re assuming /var/www/project1 is the public root of your website and you should run this as your web user or current user if you’re using Windows.

sspak load project1.sspak /var/www/project1

Create a remote snapshot

In the snapshots interface you can click ‘Create Snapshot’ which will present you with the following options:

Create a Snapshot

Select the environment from the dropdown then select the type of snapshot you want to create. The types are:

  • Database & Assets - This includes an SQL dump of the database and everything in the SilverStripe assets folder.
  • Database only - This includes only the SQL dump.
  • Assets only - This includes only the files in the assets folder.

When you’ve selected your options you can click the ‘Create’ button which will start the snapshot progress. This can vary in time depending on the size of the snapshot that you’re creating.

Snapshot creation progress

Upload a snapshot

You can upload your file through the form then tell us what the sspak contains and which environment it should belong to (or where you intend to restore it). Ownership can be changed and the snapshot can be transferred between environments once the file is uploaded.

Upload a Snapshot

After doing this hit the ‘Upload File’ button and you’ll see your snapshot successfully upload.

Large snapshots

If your sspak is larger than the maximum file size limit (2GB) then you can click the ‘File exceeds 2GB?’ button. This will provide further instructions on how you can send files to us that are too large to be uploaded.

Restore a remote snapshot

Snapshots which you have permission to view are listed in the snapshots page of your stack. To restore to an environment you can click the ‘Restore’ link next to the snapshot you want to restore, select the environment and restore it. From here you can select the environment you want to restore to and what you want to transfer.

Restore a Snapshot

Snapshot permissions

By default only Deployers, Release Managers, and Stack Managers are able to see production snapshots. This means that other team members will only have access to the UAT snapshots and snapshots of any extra environments.

If you’d like to make production snapshots available to other environments you can use the ‘move’ feature and change the owner to your target environment. This will give everyone who has snapshot permissions on the target environment permission to access that snapshot.

For further information on permissions and roles please see the roles section.