Last active
October 5, 2023 09:11
-
-
Save skoji/41de838c73aa6c33c40108cba60bf7c8 to your computer and use it in GitHub Desktop.
Mastodon : execute assets:precompile on a local machine.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# on the mastodon server | |
cd /home/mastodon/live | |
git checkout <release tag> | |
docker-compose pull && docker-compose build && docker-compose stop | |
# on the local machine | |
rsync -trzv --delete --rsync-path='sudo rsync' mastodon@server.example.com:/home/mastodon/live/ backup # get full backup | |
cd backup | |
docker-compose pull && docker-compose build && docker-compose run --rm web rails assets:precompile | |
cd .. | |
rsync -trzv ./backup/public mastodon@skoji:/home/mastodon/live/ # write back the public directory | |
# on the mastodon server | |
docker-compose up -d |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment