Step 1: Install Blocklight
Choose the installation method that fits your use case:Option A: Docker (Production)
For: 24/7 monitoring, production servers, team deploymentsWhy Docker? Auto-restart, operational metrics, resource isolation, easy updates
The API is optional. The core runtime security engine works standalone. Only enable the REST API (
--profile api) if you need HTTP endpoints for dashboards or external integrations.Option B: Local CLI (Development)
For: Rule development, backtesting exploits, testingOption C: Global Install (Daily Use)
For: Using Blocklight like other security tools from the command lineStep 2: Write Your First Rule
Best Practice: For new rules, start by creating them in
rules/testing/ to test safely, then move to rules/custom/ when ready. Rules in rules/testing/ are never loaded in production.rules/custom/my_first_rule.yaml (or rules/testing/my_first_rule.yaml for testing):
rules/custom/my_first_rule.yaml
Step 3: Validate the Rule
Step 4: Test Against Real Transactions
Step 5: Deploy & Activate
Hot Reload: Blocklight watches your rules directories. When you add or modify
.yaml files, rules reload automatically—no restart required!Next Steps
- Learn more about writing rules
- Configure alert channels