@somegregariousdude@dragonscave.space
Post #2249287
2026-05-04 01:49 UTC
Claude Code came in clutch yet again for me. I needed a local maintenance script that would do three things: 1. Backup Tuwunel's database on a regular schedule. 2. Purge remote media after 30 days. 3. Purge local media after 60 days. The thing I discovered about Tuwunel is that it's Docker container essentially is just one Rust-based binary, and if it's running, you can't invoke it using traditional Docker commands as it would essentially try to run a second instance of Tuwunel. That causes a clash with Tuwunel's database, which essentially is locked by the first instance while running. Claude's solution: It helped me write a bash script that logs into the server as my admin account and uses the Matrix API to send commands to my server's admin room that invokes the maintenance tasks needed to keep the database backed up and purges media on the schedule I set. So now I have a cron job that fires on a schedule that runs the script, it does its thing and Tuwunel stays happy, healthy and backed up without consuming all the storage space on the VPS it runs on. #Claude #AI #Tuwunel #Matrix #BashScripts #Maintenance
Replies (0)
No replies.