Specbee: How to Setup a Drupal Site on Pantheon from Scratch

How to Setup a Drupal Site on Pantheon from Scratch Karishma 02 May, 2023 Subscribe to our Newsletter Now Subscribe Leave this field blank

Did you know Pantheon is one of the largest hosting providers for Drupal websites the world over? As of 2021, they host over 300,000 Drupal sites*! Launched in 2010, Pantheon offered Drupal-specific hosting environment that was optimized for Drupal websites. As a website management platform, they offer an integrated set of services and tools allowing teams to build, launch, and manage websites. 

Drupal and Pantheon are a great match. Find out more about this as you read on AND also learn how to install Drupal on Pantheon from scratch. There’s more! You will also find out about setting up Pantheon locally, interesting commands for transfers, command line interactions and more. Dive in!

Image removed.

Why do Drupal developers Love Pantheon

Drupal developers prefer Pantheon because it is easy to use and set up, but more importantly because it offers an environment optimized for Drupal sites. Even the security features are specifically tailored to the needs of Drupal websites. A few more reasons why Pantheon is a great choice for developers:

  • Automated backups, security monitoring and Automated updates.
  • Website Performance Monitoring using New Relic
  • Git and Version control on all domains
  • Redis and Varnish cache to speed-up page delivery by caching
  • Multi-dev environment to easily keep track of code changes
  • Highly responsive Pantheon support team to help work through server related issues and technical issues.

Setting Up Drupal on Pantheon

It really is a very straightforward process. Follow the steps below to setup Drupal 9 on Pantheon

1. Visit https://pantheon.io/ to register to Pantheon using your email address

2. Click on Get Started

Image removed.

3. Once logged in, you will be land on the workspace page

4. Click on Create New Site as shown below.

Image removed.

 

5. Choose what kind of site you want to create. Let’s go with Drupal 9. Read this article to find out why.

Image removed.

 

6. Provide your Pantheon site details like the Name of the Site and continue.

Image removed.

 

7. This process will take a few moments. Once it's done, click on “Visit Pantheon Site Dashboard.”

Image removed.

 

8. Visit your website, by clicking “Visit Development Site”.

Image removed.

Installing and Customizing your Drupal 9 site

Now that you have set up Drupal on Pantheon, let’s install and customize your Drupal site. Upon visiting your website for the first time, you will be directed to the Drupal installation page.

  • Choose the language of your choice. I’ll go with English.
  • Choose the Standard Installation profile. 
Image removed.

 

  • Configure your site with information like Name of the site, Site Email Address, Username and password.
  • Hit Save.
Image removed.

 

And your Drupal 9 site is ready!

Image removed.

Setting Up Pantheon Locally

Using the following commands to set up Pantheon on your local system:

Create a new directory “pantheon” and enter it
mkdir pantheon && cd pantheon

Go through interactive prompts to get your site from Pantheon and create a .lando.yml file
lando init 

Start up the application
lando start

Import your database and files
lando pull

Transfering Files with the Get and Put Command

The Get and Put commands help create a file transfer request in SFTP.

  • First, login to the server using the SFTP command provided in Connection Info
Image removed.

 

  • If you’re logging in for the first time, you need to generate machine tokens to uniquely identify your machine and securely authenticate yourself. Find out how to generate machine token here.
Image removed.

 

Use the GET command to transfer files from a remote server to your local system

get
get -r

Use the PUT command to transfer files from your local system to the remote server

put
put -r

Terminus Command Line Tool

Terminus is a command-line interface (CLI) provided by Pantheon, which allows you to manage Drupal sites using a set of powerful tools. It is built on top of the Drush command-line tool, and provides additional functionality that is specific to Pantheon.

Developers can manage their Drupal sites from the command line, without the need to use the Pantheon dashboard.

To install Terminus, go here: https://docs.pantheon.io/terminus/install

Format of the terminus command: terminus command:subcommand .

The terminus command structure includes . in order to determine the target site and environment to execute the command.

For example, running the clear cache command for the Dev environment of a site labeled "techxspecbee"

Image removed.

 

To run the configuration import drush cim command for the Live environment of a site labeled "techxspecbee"

Image removed.

 

We can get a list of all available commands using

Image removed.

 

Image removed.

 

* References: https://www.drupal.org/pantheon

Drupal provides a robust content management system that is flexible and highly customizable, while Pantheon provides a secure and scalable hosting platform that is optimized for Drupal sites. The combination of Drupal and Pantheon allows developers to build websites quickly and easily, while also ensuring that they are secure and performant. With features like automatic backups, continuous integration, and easy site management, Pantheon is a great platform for Drupal developers looking to build websites that can scale with their projects. Are you looking for Drupal experts to build and manage your Pantheon-hosted site? We’d love to  help! Contact us today and let’s get started.

Email Address Subscribe Leave this field blank Drupal Drupal 9 Drupal Development Drupal Planet Drupal Tutorial

Leave us a Comment

 

Recent Blogs

Image Image removed.

How to Setup a Drupal Site on Pantheon from Scratch

Image Image removed.

Understanding Update and Post Update Hooks for Successful Drupal Site Updates

Image Image removed.

Embracing Achievements - Gagana Girish’s Living Dream

Want to extract the maximum out of Drupal? TALK TO US

Featured Case Studies

Image removed.Image removed.

Upgrading the web presence of IEEE Information Theory Society, the most trusted voice for advanced technology

Explore
Image removed.Image removed.

A Drupal powered multi-site, multi-lingual platform to enable a unified user experience at SEMI

Explore
Image removed.Image removed.

Great Southern Homes, one of the fastest growing home builders in the US, sees greater results with Drupal

Explore
View all Case Studies
PubDate

Tags