• 1 Post
  • 199 Comments
Joined 2 years ago
cake
Cake day: June 1st, 2023

help-circle



  • And if you want some customisation, e.g. some repeating string over and over, you can use something like this:

    yes "b0M" | tr -d '\n' | head -c 10G | gzip -c > 10GB.gz
    

    yes repeats the given string (followed by a line feed) indefinitely - originally meant to type “yes” + ENTER into prompts. tr then removes the line breaks again and head makes sure to only take 10GB and not have it run indefinitely.

    If you want to be really fancy, you can even add some HTML header and footer to some files like header and footer and then run it like this:

    yes "b0M" | tr -d '\n' | head -c 10G | cat header - footer | gzip -c > 10GB.gz
    





  • Ohh, SQLite isn’t “one” db. SQLite is file-based. I.e. a database in e.g. PostgreSQL (containing several tables, views, indexes, etc.) would translate to one SQLite file (e.g. mydatabase.db3 or myappdata.sqlite). And each app has its own file/database. If the file corrupts, then it’s only affecting that specific app. (However, SQLite is pretty robust.) And since these are just files, you can backup them together with the application. No need to export data or shutdown the database first.






  • On the receiving end of this controller, there’s probably just a relay shorting 2 wires from the boiler together - like the Honeywell BDR91.

    So, you could just replace that by some Shelly switch and wouldn’t have to use the proprietary radio protocol.

    On a sidenote: Those room controllers usually “learn” how long it takes to reach the target temperature (as this can be vastly different between summer and winter) and move the starting time accordingly. So they reach the target temperature at the programmed time. At least the more expensive ones do. You’d have to do something similar in your automation if you want that comfort. (Unless HA already has some code for that…)






  • If you spin up a Lemmy instance and subscribe to a community, all new posts and comments inside that community will be mirrored to your instance. As I’m subscribed to around 100 different communities, that was a LOT of traffic without me doing anything. That’s why I’ve given up on self-hosting Lemmy just for myself and went back to using lemmy.ml.

    However, I do self-host a GoToSocial server just for myself. It’s probably not necessary as mastodon.social isn’t going anywhere anytime soon, but if you’re on a smaller instance, it might be worth it. Also, you get to show off your own domain name. And, while other instances may block yours, your content stays online as long as YOU want it to. There’s no way for an external moderator to delete posts on your own server.

    People can find you via Boosts from others or by searching for your @username@domain.com.

    Maintaining my GoToSocial so far consisted of simply getting WatchTower to update the Docker container. Migration of data to a new version happens automatically. (Well, there was one accident where some pre-release version got released under the latest tag and I had to use the development branch for a few days … but that was an accident from the GtS-team and shouldn’t happen again.)