Home

>

Tools

>

Ghost

>

Releases

>

4.22.4

Ghost Release: 4.22.4

Tag Name: v4.22.4

Release Date: 11/19/2021

Ghost LogoGhost

Open-source publishing platform specifically designed for professional bloggers and publications. Focuses on clean, minimalist writing and publishing experience.

TL;DR

Ghost v4.22.4: Enhanced Card Styles & Performance Improvements

This release brings significant enhancements to Ghost's card system with improved styling for callout, toggle, NFT, and gallery cards. It also includes important bug fixes for permissions errors when building public assets and SES mail transport credentials. Under the hood, performance improvements reduce database queries during initialization and refactor the URL service for better maintainability.

Highlight of the Release

    • Enhanced styling for callout, toggle, NFT, gallery, and bookmark cards
    • Fixed permissions error when building public assets
    • Fixed credentials provider for SES mail transport
    • Refactored URL generator with dependency injection pattern
    • Reduced database queries during initialization for better performance

Migration Guide

No migration steps are required for this release. The update is backward compatible and should not affect existing content or configurations.

If you're using SES mail transport with IAM authentication in containers, this update will fix authentication issues you may have been experiencing.

Upgrade Recommendations

This release is recommended for all Ghost users, especially those who:

  1. Use callout, toggle, NFT, gallery, or bookmark cards in their content
  2. Run Ghost in production environments where permissions are properly configured
  3. Use SES mail transport with IAM authentication in containers
  4. Would benefit from the performance improvements during initialization

The update contains no breaking changes and should be safe to apply to all installations.

Bug Fixes

Critical Fixes

  • Fixed permissions error when building public assets - Resolved issue where Ghost couldn't write to the core folder in correctly configured production installations
  • Fixed credentials provider for SES mail transport - Added missing dependency to allow authentication to SES in containers using IAM
  • Fixed transaction logic in data importer - Corrected transaction handling to properly commit or rollback based on promise chain resolution

Other Fixes

  • Added logging of unexpected errors in oembed service - Improved debugging capabilities while maintaining security
  • Fixed missing bottom spacing on email callout cards
  • Fixed NFT card rendering - Updated to handle the switch from card_type to type and removal of HTML property

New Features

Enhanced Card System

  • Callout Cards: Added variable background color support with semi-transparent backgrounds for dark mode compatibility, improved email styles, and refined rendering
  • Toggle Cards: Added open/close behavior, updated styling, and improved email rendering
  • NFT Cards: Added custom embed card rendering with proper metadata handling, email styles using tables, and OpenSea logo integration
  • Gallery & Bookmark Cards: Updated CSS for improved appearance
  • Button Cards: Added AMP support and styling

Configuration Improvements

  • Tenor Integration: Added tenor:contentFilter setting and moved tenorApiKey to tenor:apiKey with updated configuration structure
  • Card Assets: Added support for config.card_assets flag in GScan to disable card asset checks when enabled

Security Updates

No significant security fixes were included in this release.

Performance Improvements

Database and Initialization Optimizations

  • Reduced unnecessary DB queries during initialization - Updated knex-migrator to batch inserts and remove redundant SELECT queries, reducing initialization time and eliminating approximately 470 DB queries
  • Added performance-improving PRAGMAs in testing mode - Implemented optimizations to improve test execution speed
  • Removed unnecessary settings load in tests - Saves approximately one second in local test execution

Code Optimization

  • Lazy loaded cheerio dependency - Moved requires later into the code when they are needed to improve boot time and memory usage
  • Added URL Service boot log - Added visibility into when URL Service finishes loading, which is when Ghost stops serving 503s

Impact Summary

Ghost v4.22.4 delivers significant enhancements to the card system with improved styling and functionality for callout, toggle, NFT, gallery, and bookmark cards. These improvements provide better visual consistency across different viewing contexts including dark mode themes and email.

The release also addresses important infrastructure issues, fixing permissions errors when building public assets and resolving authentication problems with SES mail transport in containerized environments.

Under the hood, performance optimizations reduce database queries during initialization, and the URL service has been refactored for better maintainability and testability. These changes improve the overall robustness and efficiency of the Ghost platform.

Content creators will benefit from the enhanced card styling and functionality, while developers will appreciate the code refactoring and improved testability. Site administrators will see better performance during initialization and fewer issues with mail transport and asset building.

Full Release Notes

  • 🐛 Fixed permissions error when building public assets - Hannah Wolfe
  • 🐛 Fixed credentials provider for SES mail transport - Marat Vyshegorodtsev
  • 🐛 Fixed Casper not being installable from themes list - Kevin Ansfield
  • 🐛 Fixed Unsplash image selector being available in editor when disabled - Kevin Ansfield

View the changelogs for full details:

Statistics:

File Changed131
Line Additions4,817
Line Deletions1,622
Line Changes6,439
Total Commits89

User Affected:

  • Enhanced styling for callout, toggle, NFT, gallery, and bookmark cards
  • Improved dark mode support for callout cards
  • Better email rendering for various card types

Contributors:

renovate-botallouisnazsanne-sanrshbhgrgdaniellockyerErisDSsam-lordkevinansfieldminimaluminiumpeterzimondjordjevlaistpatel