YunoHost-Apps / mastodon_ynh

Free, open-source social network for YunoHost
https://joinmastodon.org/
GNU Affero General Public License v3.0
85 stars 36 forks source link

how to migrate existing instance database to fresh install? #384

Closed SmallPatatas closed 1 year ago

SmallPatatas commented 1 year ago

Describe the bug

Trying to figure out if there is a way to migrate an instance on YunoHost using the method described here, where the essential files are transferred to a new Mastodon install (but without the Mastodon:setup step): https://docs.joinmastodon.org/admin/migrating/

Context

I had changed the character limit as described here https://www.draklyckan.se/2021/11/how-to-increase-the-character-limit-for-toots-in-mastodon/ but was getting a notification at the RAILS_ENV=production bundle exec rails assets:precompile step that (to the best of my recollection) said I should upgrade npm.

So, naively, I did that. Now I'm in what I think people call "dependency hell" where the Mastodon homepage is a blank screen on everyone else's computer/phone but my own, and compiling fails with things like "update postcss to version 8" even though it seems to already be there.

I'm really out of my depth as a noob here :/

So I'm hoping that I can find a way to reinstall YunoHost/Mastodon in such a way that I can migrate the database, secrets, etc rather than do a 'backup/restore' in the standard YunoHost way for installs that haven't been broken by a silly noob admin

Thanks :)

Tagadda commented 1 year ago

I think you could try to restore the backup and then force an app upgrade with sudo yunohost app upgrade mastodon -F.