Shell Executor
The shell executor runs commands via sh -c with full payload interpolation support.
Basic usage
[hooks.executor]
type = "shell"
command = "echo 'hook triggered'"
With interpolation
[hooks.executor]
type = "shell"
command = "cd /app && git checkout {{branch}} && make deploy"
All interpolated values are shell-escaped automatically.
Working directory
[[hooks]]
name = "Build"
slug = "build"
cwd = "/opt/project"
[hooks.executor]
type = "shell"
command = "make build"
Environment variables
[hooks.env]
DEPLOY_ENV = "production"
API_KEY = "${{EXTERNAL_API_KEY}}"
Environment variable values can reference host environment variables using ${{VAR_NAME}} syntax.
Timeout
Per-hook timeout (overrides global default):
[[hooks]]
slug = "long-task"
timeout = "5m"
If a command exceeds its timeout, the process is killed and the execution is marked as TimedOut.
Output capture
stdout and stderr are written to separate log files:
data/logs/{execution_id}/stdout.log
data/logs/{execution_id}/stderr.log
The original payload is saved as payload.json in the same directory.