github mastodon/mastodon v4.5.0-beta.2

pre-releaseone day ago

Mastodon

Warning

This is a pre-release! This has not been as widely tested as regular releases, although it is still tested on mastodon.social and some other servers. If you update to this release, you will not be able to safely downgrade to the existing stable releases. You will, however, be able to upgrade to later nightly releases or pre-releases, as well as the upcoming 4.5.0 stable release.

Upgrade overview

This release contains upgrade notes that deviate from the norm:

⚠️ The minimum supported version for Redis has been bumped to 7.0
⚠️ Rolling updates from versions earlier than Mastodon 4.3 are not supported
⚠️ Import jobs from Mastodon versions earlier than Mastodon 4.2 are not supported
ℹ️ Sidekiq has been updated, which may require you to change health check or monitoring code
ℹ️ Requires streaming server restart
ℹ️ Requires database migrations

For more information, view the complete release notes and scroll down to the upgrade instructions section.

Changelog (v4.5.0-beta.2)

Security

Added

Changed

  • Change appearance settings to introduce new Advanced settings section (#36496 and #36506 by @diondiondion)
  • Change docker-compose.yml sidekiq health check to work for both 4.4 and 4.5 (#36498 by @ClearlyClaire)
  • Change fetch-all-replies to show new replies early if the task takes long to finish (#36481 by @diondiondion)

Fixed

Changelog (v4.5.0-beta.1)

Added

Changed

Fixed

Upgrade notes

To get the code for v4.5.0-beta.2, use git fetch && git checkout v4.5.0-beta.2.

Note

As always, make sure you have backups of the database before performing any upgrades. If you are using docker-compose, this is how a backup command might look: docker exec mastodon_db_1 pg_dump -Fc -U postgres postgres > name_of_the_backup.dump

Dependencies

External dependencies have changed since v4.4.0, with the Redis minimum version being higher.

  • Ruby: 3.2 or newer
  • PostgreSQL: 13 or newer
  • Elasticsearch (recommended, for full-text search): 7.x (OpenSearch should also work)
  • LibreTranslate (optional, for translations): 1.3.3 or newer
  • Redis: 7.0 or newer
  • Node: 20 or newer
  • libvips (optional, instead of ImageMagick): 8.13 or newer
  • ImageMagick (optional if using libvips): 6.9.7-7 or newer

Sidekiq update and health checks

We have updated Sidekiq from Sidekiq 7 to Sidekiq 8, but the health check we provide in docker-compose.yml (which is intended for releases) specifically checks for Sidekiq 7. If you use it or have a similar health check, you will need to update it to test for Sidekiq 8.

Instead of the following line:

test: ['CMD-SHELL', "ps aux | grep '[s]idekiq\ 7' || false"]

It should read:

test: ['CMD-SHELL', "ps aux | grep '[s]idekiq\ 8' || false"]

Update steps

The following instructions are for updating from 4.4.7.

If you are upgrading directly from an earlier release, please carefully read the upgrade notes for the skipped releases as well, as they often require extra steps such as database migrations. If you are upgrading from a pre-4.3 version, please fully update to Mastodon 4.3 first or stop all Mastodon processes before updating, and please have a look at the “Ongoing import jobs from Mastodon 4.1 and earlier” section of Mastodon 4.4.0's release notes if you are updating from a pre-4.2 version.

Non-Docker

Tip

The charlock_holmes gem may fail to build on some systems with recent versions of gcc.
If you run into this issue, try BUNDLE_BUILD__CHARLOCK_HOLMES="--with-cxxflags=-std=c++17" bundle install.

  1. If you are using rbenv, update the list of available versions and install the proper Ruby version by doing RUBY_CONFIGURE_OPTS=--with-jemalloc rbenv install in the Mastodon install directory (e.g. /home/mastodon/live)
  2. Install dependencies with bundle install and yarn install --immutable
  3. Precompile the assets: RAILS_ENV=production bundle exec rails assets:precompile
  4. Run the pre-deployment database migrations by specifying the SKIP_POST_DEPLOYMENT_MIGRATIONS=true environment variable: SKIP_POST_DEPLOYMENT_MIGRATIONS=true RAILS_ENV=production bundle exec rails db:migrate
  5. Restart all Mastodon processes.
  6. Run the post-deployment database migrations: RAILS_ENV=production bundle exec rails db:migrate

When using Docker

  1. Run the pre-deployment database migrations by specifying the SKIP_POST_DEPLOYMENT_MIGRATIONS=true environment variable: docker-compose run --rm -e SKIP_POST_DEPLOYMENT_MIGRATIONS=true web bundle exec rails db:migrate
  2. Restart all Mastodon processes.
  3. Run the post-deployment database migrations: docker-compose run --rm web bundle exec rails db:migrate

Update steps from 4.5.0-beta.1

The following instructions are for updating from 4.5.0-beta.1, see the section above if you are updating from an older version.

Non-Docker

Tip

The charlock_holmes gem may fail to build on some systems with recent versions of gcc.
If you run into this issue, try BUNDLE_BUILD__CHARLOCK_HOLMES="--with-cxxflags=-std=c++17" bundle install.

  1. Install dependencies with bundle install and yarn install --immutable
  2. Precompile the assets: RAILS_ENV=production bundle exec rails assets:precompile
  3. Restart all Mastodon processes.

When using Docker

  1. Restart all Mastodon processes.

Don't miss a new mastodon release

NewReleases is sending notifications on new releases.