Cartoon rocket flying into space

Getting started with Platform.sh

Thumbnail

Campbell Tilley

|

Platform.sh is a second-generation Platform-as-a-Service built especially for continuous deployment. This article will help guide you through the configuration for hosting your Drupal site on Platform.sh.

If you're looking at setting up your first Drupal 8 site hosted on Platform.sh, then this article will help get you up, up and away! 

The Platform.sh documentation is very thorough and is a great resource when you are diving deeper into the platform. When you're getting started, the documentation could be a little overwhelming and you might not know where to look.

Over the next couple of weeks, I will be posting a series of articles which will break down the documentation into a step by step guide.

Getting Started

Before we look at any configuration, we first need to ensure that our account is setup correctly and we have the necessary tools installed.

  1. If you don't already have an account, create a free trial account here
  2. Validate your account through your email. You will need to do this before proceeding to step 3
  3. Add your public key to your account by navigating to User > Account settings > SSH keys > Add a public key
  4. Install the Platform.sh CLI, inside your terminal, using
    curl -sS https://platform.sh/cli/installer | php
    You can now interact with Platform.sh via SSH sessions.
  5. Test that the CLI is working by entering platform into your terminal. This will show all of the projects attached to your account, at this stage that list will be empty

The Platform.sh CLI has many commands available for use. To see the full list of commands use the command

platform list

Create your project

We have setup our account and are now ready to create our first project.

  1. Navigate to the projects page and select Add a project
  2. Select the billing plan you would like. Unfortunately there are no Australian price offers so you will need to select either USD, EUR or GBP. Select the billing option of your choice and click Continue
  3. Now you will be brought to a wizard that will help you setup your project. You will firstly be asked to enter in the name of your project. Usually the name of your website will be sufficientPlatform.sh create a project name

     

  4. Next we will be asked to select a code base template. Select Drupal 8 from the list. As you can see, Platform.sh also has templates for many other projects.
  5. The next step asks us to again confirm the plan size we would like. You can change plans at any time so to begin, a Development plan might be sufficient for your needs
  6. Step 4 in the wizard will ask you to set your project region. This may be different to your account region depending on where the site should be hosted.
  7. The final step in the wizard is to enter your billing details. Once entered hit Complete Project

We now have a Drupal 8 site hosted on Platform.sh.

You can visit by navigating to the Master branch in the UI, that has been created for you, and clicking on Visit your site.

Platform.sh master branch with visit your site button

If you'd like to download your repo locally, you can do so either with the Platform.sh CLI or with git. The command is located at the top of the UI when you are on the branch page.

Platform.sh git command to clone repo

Up next

Next week I will explain how you can use an existing code base to build your project.

Add new comment

The content of this field is kept private and will not be shown publicly.

Plain text

  • No HTML tags allowed.
  • Lines and paragraphs break automatically.
  • Web page addresses and email addresses turn into links automatically.

Comments

  • Allowed HTML tags: <em> <strong> <cite> <blockquote cite> <ul type> <ol start type> <li> <dl> <dt> <dd> <p>
  • Lines and paragraphs break automatically.
  • Web page addresses and email addresses turn into links automatically.
  • Use [gist:#####] where ##### is your gist number to embed the gist
    You may also include a specific file within a multi-file gist with [gist:####:my_file].

Spread the word