3 ms·
Which is much easier than fiddling around with crontab, in my experience. Yes, you need a systemd service file and a systemd timer file. Creating both is a mat
by BossingAround 2y ago
Which is much easier than fiddling around with crontab, in my experience.
Yes, you need a systemd service file and a systemd timer file. Creating both is a matter of ~30m. Then, you do `systemctl start` and you're good... As a great benefit, you can see the status of each timer, which is great for debugging quick problems, like permission issues/runtime errors/... when setting the timer up.
- SSLy 2y agostart and enable, or they won't come up after reboot or target change
- deleted 2y ago[deleted]
- vaylian 2y agoHandy shortcut: systemctl enable foo.timer --now To enable and start the unit in one command.
- sgarland 2y ago> Creating both is a matter of ~30m. I can write a cron entry in a minute or two, depending on the complexity.
- BossingAround 2y agoWell, it takes 30m the first time, when learning from scratch. When learning the arcane cron entry system, I'd guess it takes even longer than 30m, unless you have a simple time in mind (like "every minute" or something similar - "every second Monday" is definitely more complex to reason about in cron). Again, comparing not knowing systemd timer vs not knowing cron.
- sgarland 2y agoSure, not saying you can just sit down and do it straight away. But the additional complexity of systemd, I think, makes it even more daunting. It’s much like how modern frontend has a million components. I understand there are or were reasons for all of it, but not everyone needs it, and it’s intimidating to a newcomer. In comparison, cron (and *nix tooling in general) asks you to learn a small bit of that tool’s syntax, and that’s it. You can add complexity if you’d like – read the man pages – but for the most part, you can be productive very quickly.
- deleted 2y ago[deleted]