dehydrated-hook(1)

πŸ“¦ in ubuntu stonking

πŸ’– dehydrated-hook(1) β€” the run-parts hook era πŸ’–

okay so bestie, you're looking at the manual page for dehydrated-hook from the dehydrated-tools-extra crew, living in section 1 (General Commands Manual). pull up a chair, we're doing hooks today πŸŽ€


✨ Name ✨

dehydrated-hook β€” the dehydrated run-parts hook. she's the middleman, the group chat admin, the one who makes sure everybody gets their turn πŸ’…


✨ Synopsis ✨

dehydrated-hook 'HANDLER'

yes that's it. one argument. she's low maintenance like that πŸ¦‹


✨ Description ✨

dehydrated is a client for ACME-based Certificate Authorities, like LetsEncrypt. it's the thing you use to request and obtain TLS certificates from an ACME-based certificate authority. iconic, honestly. no cap. πŸ”₯

so what does dehydrated-hook do? it makes it possible to run multiple scripts in every stage within the process of creating, signing and deploying a certificate. not one script. multiple. the way that it just keeps everything organized?? obsessed. πŸ’–

here's the tea on where your scripts go: they need to be placed in /etc/dehydrated/hook.d and they need to be prefixed with the name of the handler, e.g. exit_hook.example1 or exit_hook.example2.sh ✨

so like, exit_hook is the handler name, and .example1 / .example2.sh is just... you, being you, naming your little scripts whatever you want. go off. 🌸


✨ Handlers ✨

the following dehydrated handlers are available:

  • deploy_challenge
  • clean_challenge
  • sync_cert
  • deploy_cert
  • deploy_ocsp
  • unchanged_cert
  • invalid_challenge
  • request_failure
  • generate_csr
  • startup_hook
  • exit_hook

that's the whole squad, all 11 of them, no substitutes πŸ‘‘ each one is a stage where your scripts can jump in and do their little thing.


✨ Usage ✨

🧚 Installation 🧚

run these, bestie:

sudo echo HOOK="/usr/bin/dehydrated-hook" > /etc/dehydrated/conf.d/zz-hook.sh
sudo mkdir -p /etc/dehydrated/hook.d

that first line drops the HOOK setting into /etc/dehydrated/conf.d/zz-hook.sh (yes, zz- so it lands last, iykyk), and the second one creates your /etc/dehydrated/hook.d directory so your scripts have somewhere to vibe. periodt. πŸ’…

🧹 Removal 🧹

when you're done, or you just want to un-haunt your system:

sudo rm -f /etc/dehydrated/conf.d/zz-hook.sh
sudo rmdir /etc/dehydrated/hook.d

clean exit, we love to see it 🌈 (note: rmdir will only work if the directory is empty, so like... take your scripts with you, girl πŸ“)


✨ Files ✨

the following files are used:

  • /etc/dehydrated/hook.d β€” directory to place individual hooks. this is the spot. the main character location. put your hook scripts here πŸŽ€

✨ See also ✨

go read these too, they're all part of the family 🫢


✨ Homepage ✨

more information about dehydrated-tools-extra can be found on the homepage (https://open-infrastructure.net). ✨


✨ Contact ✨

bug reports, feature requests, help, patches, support and everything else are welcome on https://git.open-infrastructure.net. literally everything. come say hi πŸ’œ

Debian specific bugs can also be reported in the Debian Bug Tracking System (https://bugs.debian.org). πŸ›


✨ Authors ✨

dehydrated-tools-extra was written by Daniel Baumann <daniel@debian.org>. thank you for your service, king πŸ‘‘


just a lil reminder bestie: your scripts in /etc/dehydrated/hook.d have to be prefixed with the handler name or they simply will not run. that's not a vibe check you can skip 😭

okay that's the whole page!! this gem came to you from Open Infrastructure's dehydrated-tools-extra project β€” the dehydrated-hook(1) page, and now you know everything she knows. slay, go write some hooks, and don't forget the prefix πŸ’–βœ¨πŸ¦‹

πŸ“¦ where this page comes from