Platform.sh provides a responsive management console which allows you to interact with your projects and manage your environments.
Everything you can do with the management console you can also achieve with the CLI (Command Line Interface).
Platform.sh recently launched a new web management console. This documentation refers to the new console. To access the legacy user interface select the user drop-down in the top right and click
Legacyunder the "Console mode" option. Documentation for the legacy interface is still available until it is fully retired.
From your project's main page, each of the environments are available from the pull-down menu
ENVIRONMENTS at the top of the page.
There is also a graphic view of your environments on the right hand side, where you can view your environments as a list or as a project tree.
The name of the environment is strikethroughed if it's been disabled. If it has an arrow next to it, this means the environment has children.
The management console displays all the activity happening on your environments. You can filter messages per type.
Within a project`s environment, the management console exposes 4 main actions and 4 drop-down command options that you can use to interface with your environments.
Branching an environment means creating a new branch in the Git repository, as well as an exact copy of that environment.
The new branch includes code, all of the data that is stored on disk (database, Solr indexes, uploaded files, etc.), and also a new copy of the running services (and their configuration) that the application needs. This means that when you branch an environment, you also branch the complete infrastructure.
branch, three things happen:
- A new branch is created in Git.
- The application is rebuilt on the new branch, if necessary.
- The new branch is deployed.
Branch a dialog box will appear that will provide commands to execute future merges from the command line using the Platform.sh CLI.
Merging an environment means introducing the code changes from a branch to its parent branch and redeploying the parent.
- The code changes are merged via Git to the parent branch.
- The application is rebuilt on the parent branch, if necessary.
- The parent branch is deployed.
Rebuilding the application is not necessary if the same code was already built (for any environment): in this case you will see the message
Slug already built for this tree id, skipping.
Merge a dialog box will appear that will provide commands to execute future merges from the command line using the Platform.sh CLI.
Synchronization performs a merge from a parent into a child environment, and then redeploys that environment.
You have the option of performing a Sync on only the code, replacing the data (i.e. databases) of that environment from its parent, or both.
These options are provided in a separate dialog box that will appear when you click the
Sync button, along with the Platform.sh CLI commands that perform the same action.
Sync is only available if your branch has no unmerged commits, and can be fast-forwarded.
It is good practice to take a snapshot of your environment before performing a synchronization.
Creating a snapshot for an environment means saving a copy of the database so that it can be restored (in other words, create a backup). You will see the snapshot in the activity feed of you environment in the Platform.sh management console where you can trigger the restore by
clicking on the
Backup a dialog box will appear that will provide commands to execute future merges from the command line using the Platform.sh CLI.
You can also use the CLI with:
$ platform environment:backup
to create a snapshot, and
$ platform environment:restore
to restore an existing snapshot.
The URLs pull-down exposes the domains that can be used to access application environments from the web.
The Git pull-down displays the commands to use to clone the codebase via Git.
The CLI pull-down displays the commands to get your project set up locally with the Platform.sh CLI.
The SSH pull-down display the commands to access your project over SSH.