Make Digital Beautiful.

und schnell

Mastodon character limit increase – in a Docker environment

For the Docker Mastodon admin newbies.

With the script, you increase the character limit to 5000 characters for your instance.

docker-compose exec web sed -i ‘s/500/5000/g’ app/javascript/mastodon/features/compose/components/compose_form.js
docker-compose exec web sed -i ‘s/500/5000/g’ app/validators/status_length_validator.rb
docker-compose exec web sed -i ‘s/:registrations/:registrations, :max_toot_chars /g’ app/serializers/rest/instance_serializer.rb
docker-compose exec web sed -i ‘s/private/def max_toot_charsn 5000n endnn private/g’ app/serializers/rest/instance_serializer.rb
docker-compose exec web bundle exec rails assets:precompile && echo “pass” || echo “fail”

docker-compose restart

Save the whole thing as
Then with
Chmod +x
to make it executable. Now you can execute the script with
wait a moment and you have 5000 characters.

Tested with Mastodon v4.1.0rc3

I myself have only slightly modified the script from this forum post here

#mastodon #mastoadmin #characterlimit #docker #vps #linux #dockerizedmastodon

Leave a Comment