Skip to content
HomeKnowledge BaseStatisticsChangelog GitHub Discord Email
developer / Developer Overview

No results for ""

Developer Overview

Overview

Demyx provides two extension points for developers who want to customize its behavior without modifying core files:

  1. Custom Callbacks — hooks called by the healthcheck and monitor system to send alerts to external services (Matrix, Slack, Telegram, etc.)
  2. Custom Cron — scripts that run inside each cron interval (minute, five-minute, hourly, six-hour, daily, weekly)

Both extension points use shell scripts placed in the /demyx/custom/ directory inside the Demyx container.

File Structure

text
/demyx/custom/
├── callback.sh          # Custom healthcheck/monitor callback
└── cron/
    ├── minute.sh
    ├── five-minute.sh
    ├── hourly.sh
    ├── six-hour.sh
    ├── daily.sh
    └── weekly.sh

Getting Started

The demyx-repo includes example files in the custom/ directory:

  • custom/example-callback.sh — Matrix webhook example
  • custom/example-cron/ — example scripts for each cron interval

Copy and rename these to activate them:

bash
# Enter the Demyx container
demyx exec code

# Or via docker exec
docker exec -it --user=root demyx bash

# Copy examples
cp /path/to/example-callback.sh /demyx/custom/callback.sh
cp /path/to/example-cron/* /demyx/custom/cron/

Important Notes

  • Custom files are not overwritten by Demyx updates
  • Scripts must be executable: chmod +x /demyx/custom/callback.sh
  • Errors in custom scripts will not crash Demyx but may appear in cron logs
  • View cron output: demyx log cron