Rule Engine
The Nife Rule Engine lets you define automated actions based on conditions — triggering deployments, scaling events, or alerts without manual intervention.
What You Can Automate
- Auto-scale based on CPU or memory thresholds
- Trigger redeployments when new container images are published
- Send alerts when error rates exceed a threshold
- Suspend applications during off-peak hours to save costs
Creating a Rule
- Navigate to your application in the Nife dashboard
- Go to Automation → Rule Engine
- Click Create Rule
- Define your condition (e.g. CPU > 80%)
- Define your action (e.g. Scale up by 1 instance)
- Set the evaluation frequency
- Click Save
Rule Conditions
| Condition | Description |
|---|---|
| CPU Usage | Trigger when CPU exceeds a threshold |
| Memory Usage | Trigger when memory exceeds a threshold |
| Request Rate | Trigger based on incoming request volume |
| Error Rate | Trigger when error rate exceeds a limit |
| Schedule | Trigger at a specific time (cron expression) |
Rule Actions
| Action | Description |
|---|---|
| Scale Up | Add more instances |
| Scale Down | Remove instances |
| Redeploy | Trigger a fresh deployment |
| Suspend | Pause the application |
| Alert | Send a notification |