dunkelstern, PSA: If you're getting Error 500 messages from mastodon when trying to upload images from mobile: You're probably trying to upload a HEIC/HEIF image and the fastimage gem errors out.
Easy fix: search for fastimage in Gemfile.lock, change version to 2.3.0 and run bundle install. Then restart mastodon services.
There is a PR that has already been merged but it did not make it into a mastodon release it seems: https://github.com/mastodon/mastodon/pull/28488