Files
Charon/docs/features/live-reload.md
akanealw eec8c28fb3
Some checks failed
Go Benchmark / Performance Regression Check (push) Has been cancelled
Cerberus Integration / Cerberus Security Stack Integration (push) Has been cancelled
Upload Coverage to Codecov / Backend Codecov Upload (push) Has been cancelled
Upload Coverage to Codecov / Frontend Codecov Upload (push) Has been cancelled
CodeQL - Analyze / CodeQL analysis (go) (push) Has been cancelled
CodeQL - Analyze / CodeQL analysis (javascript-typescript) (push) Has been cancelled
CrowdSec Integration / CrowdSec Bouncer Integration (push) Has been cancelled
Docker Build, Publish & Test / build-and-push (push) Has been cancelled
Quality Checks / Auth Route Protection Contract (push) Has been cancelled
Quality Checks / Codecov Trigger/Comment Parity Guard (push) Has been cancelled
Quality Checks / Backend (Go) (push) Has been cancelled
Quality Checks / Frontend (React) (push) Has been cancelled
Rate Limit integration / Rate Limiting Integration (push) Has been cancelled
Security Scan (PR) / Trivy Binary Scan (push) Has been cancelled
Supply Chain Verification (PR) / Verify Supply Chain (push) Has been cancelled
WAF integration / Coraza WAF Integration (push) Has been cancelled
Docker Build, Publish & Test / Security Scan PR Image (push) Has been cancelled
Repo Health Check / Repo health (push) Has been cancelled
History Rewrite Dry-Run / Dry-run preview for history rewrite (push) Has been cancelled
Prune Renovate Branches / prune (push) Has been cancelled
changed perms
2026-04-22 18:19:14 +00:00

83 lines
2.7 KiB
Markdown
Executable File

---
title: Zero-Downtime Updates
description: Make changes without interrupting your users
---
# Zero-Downtime Updates
Make changes without interrupting your users. Update domains, modify security rules, or add new services instantly. Your sites stay up while you work—no container restarts needed.
## Overview
Charon leverages Caddy's live reload capability to apply configuration changes without dropping connections. When you save changes in the UI, Caddy gracefully transitions to the new configuration while maintaining all active connections.
This means your users experience zero interruption—even during significant configuration changes.
## Why Use This
- **No Downtime**: Active connections remain unaffected
- **Instant Changes**: New configuration takes effect immediately
- **Safe Iteration**: Make frequent adjustments without risk
- **Production Friendly**: Update live systems confidently
## How It Works
When you save configuration changes:
1. Charon generates updated Caddy configuration
2. Caddy validates the new configuration
3. If valid, Caddy atomically swaps to the new config
4. Existing connections continue on old config until complete
5. New connections use the updated configuration
The entire process typically completes in milliseconds.
## What Can Be Changed Live
These changes apply instantly without any restart:
| Change Type | Live Reload |
|-------------|-------------|
| Add/remove proxy hosts | ✅ Yes |
| Modify upstream servers | ✅ Yes |
| Update SSL certificates | ✅ Yes |
| Change access lists | ✅ Yes |
| Modify headers | ✅ Yes |
| Update redirects | ✅ Yes |
| Add/remove domains | ✅ Yes |
## CrowdSec Integration Note
> **Important**: CrowdSec integration requires a one-time container restart when first enabled or when changing the CrowdSec API endpoint.
After the initial setup, CrowdSec decisions update automatically without restart. Only the connection to the CrowdSec API requires the restart.
To minimize disruption:
1. Configure CrowdSec during a maintenance window
2. After restart, all future updates are live
## Validation and Rollback
Charon validates all configuration changes before applying:
- **Syntax Validation**: Catches configuration errors
- **Connection Testing**: Verifies upstream availability
- **Automatic Rollback**: Invalid configs are rejected
If validation fails, your current configuration remains active and an error message explains the issue.
## Monitoring Changes
View configuration change history:
1. Check the **Real-Time Logs** for reload events
2. Review **Settings****Backup** for configuration snapshots
## Related
- [Backup & Restore](backup-restore.md)
- [Real-Time Logs](logs.md)
- [CrowdSec Integration](crowdsec.md)
- [Back to Features](../features.md)