Operations Guide¶
This guide covers day-to-day operational procedures for managing the rbnk.uk infrastructure.
Overview¶
The operations documentation provides detailed procedures for maintaining, monitoring, and managing the self-hosted infrastructure. All services are containerized using Docker and managed through docker-compose configurations.
Key Operational Areas¶
DNS Management¶
Manage DNS records through Cloudflare, including: - Creating and updating DNS records - SSL certificate management - Domain routing configuration
Backup Strategy¶
Comprehensive backup procedures including: - Automated daily backups to Cloudflare R2 - Cloud storage synchronization with Rclone - Database backup procedures - Recovery workflows
Monitoring¶
Infrastructure monitoring with: - Prometheus metrics collection - Grafana dashboards - Loki log aggregation - AlertManager notifications
Security¶
Security procedures including: - Access control management - Secret rotation - Security updates - Audit procedures
Maintenance¶
Regular maintenance tasks: - Docker image updates - Disk space management - Performance optimization - Health checks
Proxmox Port Forwarding¶
Managing external access through Proxmox: - Port forwarding configuration - NAT rules management - Service exposure
Tailscale Access¶
Secure VPN access configuration: - Tailscale setup and management - MagicDNS configuration - Access control policies
Quick Commands¶
Check Service Status¶
# View all running services
docker ps
# Check specific service
docker compose -f SERVICE/docker-compose.yml ps
# View service logs
docker compose -f SERVICE/docker-compose.yml logs -f
Restart Services¶
# Restart specific service
docker compose -f SERVICE/docker-compose.yml restart
# Recreate service (pull latest image)
docker compose -f SERVICE/docker-compose.yml up -d --force-recreate
Backup Operations¶
# Manual backup
/srv/dockerdata/rclone/backup-infrastructure.sh
# Check backup status
docker exec rclone rclone ls cloudflare:infrastructure-backups
Monitoring¶
# Check Prometheus targets
curl http://localhost:9090/api/v1/targets | jq
# View active alerts
curl http://localhost:9090/api/v1/alerts | jq
Emergency Procedures¶
Service Recovery¶
- Check container status:
docker ps -a - View logs:
docker logs CONTAINER_NAME - Restart if needed:
docker restart CONTAINER_NAME - Check Traefik routing if external access issues
Disk Space Issues¶
- Check usage:
df -h - Clean Docker:
docker system prune -a - Check logs:
du -sh /srv/dockerdata/*/logs - Review backups:
ls -lah /srv/dockerdata/_backup/
Network Issues¶
- Check Docker networks:
docker network ls - Verify Traefik:
docker logs traefik - Test internal connectivity:
docker exec CONTAINER ping OTHER_CONTAINER - Check Proxmox port forwarding if external access issues
Best Practices¶
- Always backup before major changes
- Use the backup scripts in
_scripts/ -
Verify backups are successful
-
Monitor resource usage
- Check Grafana dashboards regularly
-
Set up alerts for critical thresholds
-
Document changes
- Update relevant documentation
-
Commit configuration changes to Git
-
Test in isolation
- Use separate test stacks when possible
-
Verify changes before applying to production
-
Security first
- Never expose services without authentication
- Rotate credentials regularly
- Keep services updated
Support Resources¶
- Logs: Check service logs first for troubleshooting
- Monitoring: Use Grafana dashboards for performance insights
- Documentation: Refer to service-specific docs in
/srv/dockerdata/docs/services/ - Backups: Always available in Cloudflare R2 for disaster recovery