8000
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can you add a feature such that whenever the sablier triggers the container start signal it can also has the ability to execute a custom bash script.
For example something like on_start
on_start
subdomain.example.com { sablier http://localhost:10000 { group glances session_duration 1h dynamic on_start /bin/bash /home/ubuntu/myscript.sh } reverse_proxy http://localhost:1234 }
The text was updated successfully, but these errors were encountered:
Can you provider more details on what this feature would allow you to do ?
I think something quite similar is described here: #423
But instead of specifying a something to execute, you could subscribe to such event directly and do whatever you want.
I think it would give you more flexibility, but also require more setup because you need an http server to listen to the webhook events.
Sorry, something went wrong.
I think this is adjacent to the fix for #159 as this functionality would enable arbitrary calls to other machines and services. It could trigger a webhook (leveraging curl directly perhaps), call out to an external machine over SSH or SNMP, there are a lot of options...
I was considering this sort of approach for integration with hypervisors like Proxmox, you could bring a VM or container up/down as requested. Having a layer of abstraction provided by bash (or any scripting language) between the start/stop request and the target would also allow for formatting of messages for specific APIs or generation of notifications for events.
I think a good paradigm for this setup would be to follow what @r4nchy is suggesting, but specify the script as on_event or something, then passing the event type as an environment variable or command line argument. The environment could also be setup to include useful variables like URL, group, etc.
on_event
No branches or pull requests