Harsh Shandilya on Nostr: #TIL: You can run `systemctl cat servicename.service` to get the "final" version of ...
#TIL: You can run `systemctl cat servicename.service` to get the "final" version of your #systemd service file, including all overrides which would typically be loaded dynamically by systemd itself and not visible in the actual unit file.
This is extremely helpful on #NixOS where packages can sometimes re-use upstream systemd unit files and inject NixOS specific options through an override file which can be non-obvious.
The attached image shows the extra information it's able to surface
Published at
2025-01-04 13:27:34Event JSON
{
"id": "383e6239abaa179fc71e493201cb42613897553c67ed5d84f9f4b115a9b7c3bd",
"pubkey": "cefdae4605a118a6df6dfab4bb1345c7e218cbce8f112560e3851046f4234294",
"created_at": 1735997254,
"kind": 1,
"tags": [
[
"t",
"til"
],
[
"t",
"systemd"
],
[
"t",
"nixos"
],
[
"imeta",
"url https://cdn.masto.host/androiddevsocial/media_attachments/files/113/770/315/855/482/780/original/7dd0e7a61a648287.png",
"m image/png",
"dim 1967x590",
"blurhash U14Ld:.8%gx]RCt8t8t8V]ogt7t7.Rozjujb"
],
[
"proxy",
"https://androiddev.social/users/msfjarvis/statuses/113770316060684895",
"activitypub"
]
],
"content": "#TIL: You can run `systemctl cat servicename.service` to get the \"final\" version of your #systemd service file, including all overrides which would typically be loaded dynamically by systemd itself and not visible in the actual unit file.\n\nThis is extremely helpful on #NixOS where packages can sometimes re-use upstream systemd unit files and inject NixOS specific options through an override file which can be non-obvious.\n\nThe attached image shows the extra information it's able to surface\n\nhttps://cdn.masto.host/androiddevsocial/media_attachments/files/113/770/315/855/482/780/original/7dd0e7a61a648287.png",
"sig": "c922aa207aaa7b71f81129a63caa4e3046d404bdbf8539dba7c2158435f412e6020fdd338283e157d594b40af5f20fa0fbe4d042e17b529d26e61062f9aa3b09"
}