Hosting with Pantheon - ucsf-ckm/ucsf-library-ux-and-web-documentation GitHub Wiki

Migration

After seven years, we moved hosting for library.ucsf.edu from Flywheel/WP Engine to Pantheon starting the end of Dec. 2022. The main reason was because UCSF has an account and many other campus sites are hosted there.

Overview

Pantheon is structured like this:

  • Dev environment
  • Test environment
  • Live environment

see code vs content

Commit Code in Dev

  • Code is writable in the Dev (or a Multidev) environment, but is locked in Test and Live. After changes are pushed to Dev, the Deploys panel in the Test tab will prompt you to commit the changes to Test

Combine Code from Dev and Content from Live in Test

  • When you're ready to test a new set of changes, deploy your code from Dev to Test. At this point, you will be prompted to clone your content down from the Live environment.

Deploy Code to Live.

  • Deploying code from Test to Live will immediately update your public website

Workflow methods

WordPress dashboard

  • Most day-to-day edits will be done via WordPress login in the Live environment. That includes all news posts, page content edits, etc. Custom CSS changes can be done here via the Simple CSS plugin.

Pantheon dashboard

  • Code updates must be done in the Dev environment. This includes core, theme, and plugin updates. It does not include CSS changes, code snippets in the Snippets plugin, etc. Video

Autopilot

Autopilot automatically detects and applies CMS updates, including modules, plugins, and themes. Visual regression testing (VRT) checks for errors before deploying to your chosen environment.

SFTP or Git

  • changes can also be done via Git, but switch back to SFTP to do app updates

Multidev

  • how should this be used?

Updating core and plugins manually

  • WordPress core: Pantheon Dev tab for There are no updates This site is running the latest version of WordPress. When updates are available, they will appear here.
  • Plugins: Pantheon dashboard for ucsf-library > Dev tab > Site Admin to get to WP dashboard and check updates. Once some are updated, return to Pantheon dashboard and write a good commit comment with list of plugins.
Plugin maintenance:
- Delete WP Migrate Lite
- Delete Yoast Test Helper
- Update Yoast SEO
- Update Auto Image Attributes From Filename With Bulk Updater
- Update Disable Comments
- Update Relevanssi
  • For some plugins and our theme, we float patches for accessibility fixes. If you've updated an item below, use the git command line to cherry-pick the relevant patch (git checkout master && git pull && git cherry-pick <hash value from below>), and then push the change to Pantheon (git push).

    • Elementor: 74e7062e1d0a817c255f72925c72839332be38e9 and 0a9a33b39f38ff987a81e4bb72be2fd105e9c1a5

    • Elementor Pro: 8c482f9e4962d8d583463e6bb17a63ccae90e5d0 and b68927c7a647b75ab366a3a799a0749b88e97c4f

    • GeneratePress: 8333300fadbc33920ee85865d77b423c9e4d6e74

    • WPForms: 669dfdb93a8105d7dc3d8b67d76a8a7e37ed084b, b1f3b8db4a2be2a488b04093e99ee040cea7b74a, and 763d41002730caaef62269d66325698470aec7e8

    • If you're unsure of the process for these kinds of patches, you can watch a 4-minute video running through the process of updating plugins that require these kinds of patches

  • Go to Test tab and deploy what you just pushed including the same commit message. Do any testing before deploying on Live.

  • Go to Live tab and deploy what you just pushed, and it will push only the code to the live site. Same commit message.

Using Autopilot

TBD

Key Pantheon support documentation