(开启了审核注册后)Mastodon通过tootctl创建的用户还需要批准(

docker compose exec web bundle exec tootctl accounts create xxx \
--email [email protected] \
--confirmed

#mastodon #tootctl

Neues Cleanup-Script für Mastodon-Admins erstellt:

Automatisiert tootctl media remove, preview_cards remove und cache clear. Konfigurierbar via ENV-Variablen (MEDIA_DAYS, CONCURRENCY, etc.).

Features:
→ Docker & bare-metal Support
→ PID-Lock gegen parallele Ausführung
→ Dry-Run ohne CONFIRM=1
→ Tägliches Logging

Ideal für Crontab-Integration. MIT-Lizenz.

https://codeberg.org/msdong/Mastodon_Cleanup

#Mastodon #FediAdmin #tootctl #Bash #DevOps #dumango

Oh, I found a magic #mastodon #tootctl command that freed about 8GB disc space on my VPS! w00t!! (I have yet to see what this might have broken, everything seems to be working OK lol)

RAILS_ENV=production /home/mastodon/live/bin/tootctl accounts prune;

My masto install has been growing by about 500MB per day lately, even running dailly media remove --days 2

Edit to credit source of this magic: https://ricard.dev/improving-mastodons-disk-usage/

Improving Mastodon's disk usage - Ricard Torres dev

Mastodon's built-in CLI gives you the availability to clean attachments and previews from remote accounts, purging the disk cache. This is fantastic and

Ricard Torres dev

这可如何是好?
mastodon缓存出了什么问题嘛 
应该是今天下午自动清理了一次缓存,然后晚上就变成这样了
https://docs.joinmastodon.org/zh-cn/admin/tootctl/#cache-clear
我看sidekiq有很多重试、错误,和这些有关系吗  
我还试着执行了tootctl media refresh --account 但是偶尔只可以恢复头像,banner完全不能恢复
还运行了一次tootctl cache clear,但是没什么变化感觉

而且对象无一例外是关注了很多天的人,新出现的人没问题

#mastodon #admin #cache #tootctl

RE: https://mstdn.feddit.social/@admin/115710097887114149

说实话mastodon不直接支持markdown有些麻烦了;
500字符限制也有些缩手缩脚。

• 更加方便的导入emojis,注意先把已经导入的表情.tar.gz移动到地方。

for f in ~/docker/social/mastodon/main/public/system/*.tar.gz; do
name=$(basename "$f" .tar.gz)
sudo docker exec -it MASTODON_WEB_CONTAINER_NAME \
tootctl emoji import --category "$name" "/mastodon/public/system/$name.tar.gz"
done

• 需要修改的有
1. ~/docker/social/mastodon/main/public/system/*.tar.gz 本地路径
2. MASTODON_WEB_CONTAINER_NAME 实际mastodon_web容器名

#emoji #tootctl #mastodon #import

【mstdn.feddit.social使用的表情包】

https://github.com/olivvybee/emojis
• cd ~/docker/social/mastodon/main/public/system
• sudo wget https://github.com/olivvybee/emojis/releases/download/2025.04.19.1/{blobbee,fox,misc,neobread,neodlr,neofinder,neofriends,neossb}.tar.gz

https://github.com/DejavuMoe/Smoji
• wget https://github.com/DejavuMoe/Smoji/releases/download/2023.02.23/{bilibili,xiaodianshi}.tar.gz

• 导入
• sudo docker exec -it MASTODON_WEB_CONTAINER_NAME tootctl emoji import --category PACK_NAME /mastodon/public/system/PACK_NAME.tar.gz

#emoji #tootctl #mastodon #import #admin

solution found! https://mstdn.thms.uk/@michael/114993641492545398

#Mastoadmin is there a good way to find which remote accounts/domains take a ton of space with media attachments? our server's remote media cache is ballooning by 30GB *a day* and that definitely sounds wrong.
the info exists somewhere because you can see it in the admin console, but neither the admin console nor #tootctl seem to have a way to sort by attachments total size (unless i'm missing something). any advice?

#Mastodon #MastodonAdmin #selfhosting

Michael (@[email protected])

@[email protected] If you have access to the database you could run ```sql SELECT CONCAT(accounts.username, '@', accounts.domain), sum(media_attachments.file_file_size)/ 1024 / 1024 as "Total Size (MB)" FROM accounts JOIN media_attachments ON media_attachments.account_id = accounts.id WHERE media_attachments.file_file_size is not null GROUP BY CONCAT(accounts.username, '@', accounts.domain) ORDER BY sum(media_attachments.file_file_size) DESC; ``` to get the list of accounts by total file size. Or ```sql SELECT accounts.domain, sum(media_attachments.file_file_size) / 1024 / 1024 as "Total Size (MB)" FROM accounts JOIN media_attachments ON media_attachments.account_id = accounts.id WHERE media_attachments.file_file_size is not null GROUP BY accounts."domain" ORDER BY sum(media_attachments.file_file_size) DESC; ``` to get a list of instances by file size. #mastoadmin

thms.uk

Hm. Is there really no way to refresh a preview card attached to a status?

#mastodon #tootctl #MastoDev

Had a serious database failure earlier due to cascading bad decisions. I started deleting a bunch of old data, rather than using #tootctl. This led to a bunch of errors in the #pgsql #docker container.

I moved the database into bare metal using a #nuc with 32GB of RAM and 4 cores. I'm going to use this for other services too, and it was on my roadmap of transition. #nextcloud will be moving to that as well.

I'm still sorting out the fallout from this. #mastoadmin #mastodonadmin #sysop

Hey #mastoadmin people, is there something I should be running to clear up space on my mastodon server besides `tootctl media remove` and `tootctl preview-card remove`? I'm the only one on my server and somehow I have over 60GB being taken up. Doesn't seem right to me. 🤔

#server #admin #mastodon #tootctl #serveradmin