1 How to update
gitea edited this page 2025-07-10 04:09:47 +02:00

Here's the guide formatted in Markdown: markdown

Updating to glitch-soc (or updating an existing glitch-soc instance)

This guide covers updating a Mastodon instance to glitch-soc (a Mastodon fork with additional features) or updating an existing glitch-soc installation.

Update Process

1. Switch to glitch-soc source

git remote add glitch-soc https://github.com/glitch-soc/mastodon
git fetch glitch-soc
git checkout glitch-soc/main

2. Fetch the latest code
bash

git pull

3. Install dependencies
bash

bundle install && yarn install

4. Run pre-deployment database migrations
bash

RAILS_ENV=production SKIP_POST_DEPLOYMENT_MIGRATIONS=true bundle exec rails db:migrate

5. Pre-compile static assets

(Note: This is more resource-intensive than vanilla Mastodon due to multiple frontend flavors)
bash

RAILS_ENV=production bundle exec rails assets:precompile

6. Restart services
bash

systemctl reload mastodon-web
systemctl restart mastodon-sidekiq mastodon-streaming

7. Clear cache
bash

RAILS_ENV=production bin/tootctl cache clear

8. Run post-deployment migrations
bash

RAILS_ENV=production bundle exec rails db:migrate

Important Notes

    For existing glitch-soc instances, you may only need steps 2-8 (remote already exists)

    The SKIP_POST_DEPLOYMENT_MIGRATIONS flag helps minimize downtime

    Asset compilation requires more resources than vanilla Mastodon

    Consider maintenance mode if doing this on a production instance