Uberspace / lab

The Uberlab provides various tutorials - written by you! - on how to run software and tools on Uberspace 7.
https://lab.uberspace.de
Other
316 stars 417 forks source link

[adnanh / webhook] new guide #1523

Open codedust opened 1 year ago

codedust commented 1 year ago

Currently, there's no easy option to run shells scripts via incoming webhooks. Previously, it was possible to use cgi for this, but CGI is no longer officially supported.

webhook ca be used for this:

webhook is a lightweight incoming webhook server to run shell commands.

Using webhook might help some people waiting for #575.

codedust commented 1 year ago

Notes

mkdir webhook && cd webhook
go install github.com/adnanh/webhook@2.8.0   # <- make sure to replace version number
vim hooks.yaml
mkdir scripts && cd scripts
vim testhook.sh
chmod +x testhook.sh

vim ~/etc/services.d/webhook.ini
supervisorctl reread
supervisorctl update
supervisorctl status
uberspace web backend set /hooks --http --port 9000