You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
docker run --rm -e OTP_SECRET=$OTP_SECRET -e SECRET_KEY_BASE=$SECRET_KEY_BASE -it tootsuite/mastodon:latest bin/rake mastodon:webpush:generate_vapid_key | sed 's/\r//'| fly secrets import
24
+
exportMASTODON_VERSION=v4.5.7
25
+
exportSECRET_KEY_BASE=$(docker run --rm -it tootsuite/mastodon:$MASTODON_VERSION bin/rake secret)
26
+
fly secrets set SECRET_KEY_BASE=$SECRET_KEY_BASE
27
+
docker run --rm -e SECRET_KEY_BASE=$SECRET_KEY_BASE -it tootsuite/mastodon:$MASTODON_VERSION bin/rake mastodon:webpush:generate_vapid_key | sed 's/\r//'| fly secrets import
28
28
```
29
29
30
30
### Redis server
@@ -134,15 +134,17 @@ If your instance is getting slow or falling over, you may find [Scaling Mastodon
134
134
135
135
### Upgrading Mastodon
136
136
137
-
To upgrade to a new version of Mastodon, change the version number on the first line of `Dockerfile`, and then check the [release notes](https://github.com/mastodon/mastodon/blob/main/CHANGELOG.md) for upgrade instructions.
137
+
To upgrade to a new version of Mastodon, update the Mastodon image tags in [`Dockerfile`](./Dockerfile), and then check the [release notes](https://github.com/mastodon/mastodon/blob/main/CHANGELOG.md) for upgrade instructions.
138
138
139
-
If there are migrations that need to be run, make sure that the release commandin [`fly.toml`](./fly.toml) is uncommented.
139
+
This repo keeps the Fly release command enabled in [`fly.toml`](./fly.toml), so standard post-deploy migrations run automatically during `fly deploy`.
140
+
141
+
Before upgrading to Mastodon 4.5.x or newer, make sure your Fly Postgres app is already on PostgreSQL 14 or newer and your Redis app is already on Redis 7 or newer.
140
142
141
143
If there are migrations that must be run before deploying to avoid downtime, you can run the pre-deploy migrations using a second app. By scaling this app to a VM count of zero, it won't add to our bill, but it will let us run the pre-deploy migrations as a release command before the web processes get the new code.
142
144
143
145
```bash
144
146
fly apps create mastodon-example-predeploy
145
-
bin/fly-predeploy secrets set OTP_SECRET=placeholder SECRET_KEY_BASE=placeholder
147
+
bin/fly-predeploy secrets set SECRET_KEY_BASE=placeholder
0 commit comments