Skip to main content

Production Deployment Best Practices

Guidelines for deploying Aurora in production environments with security, reliability, and scalability.

Security

Secrets Management

Critical Security Requirements:
  1. Never commit secrets to version control
  2. Use strong, randomly generated passwords
  3. Rotate credentials regularly
  4. Use managed secrets services when available

Generate Strong Secrets

Kubernetes Secrets

For Kubernetes deployments, consider using: External Secrets Operator:
Sealed Secrets:

Docker Compose Secrets

For Docker Compose, use .env file with restricted permissions:
Or use Docker secrets:

Vault Configuration

Auto-Unseal with Cloud KMS

For production, configure Vault auto-unseal: AWS KMS:
GCP Cloud KMS:

Vault High Availability

For HA Vault:

Network Security

Kubernetes NetworkPolicies

Restrict pod-to-pod communication:

Pod Isolation for Untrusted Code

Enable pod isolation for terminal commands:
The chart creates NetworkPolicies that:
  • Block terminal pods from accessing cluster services (Vault, DB, etc.)
  • Allow internet access for cloud API calls
  • Isolate untrusted workloads

TLS/HTTPS Configuration

Ingress TLS with cert-manager

Install cert-manager:

Internal TLS (Service Mesh)

For encrypted internal traffic, use a service mesh: Istio:
Linkerd:

Access Control

Kubernetes RBAC

Limit who can access Aurora resources:

Rate Limiting

Enable API rate limiting:

Reliability

High Availability

Replica Configuration

Pod Disruption Budgets

Prevent simultaneous pod evictions:

Health Checks

Ensure proper health check configuration:

Resource Management

Resource Requests and Limits

Set appropriate resource limits:

Horizontal Pod Autoscaling

Backup and Recovery

PostgreSQL Backups

Automated backups with CronJob:
Managed Database Backups: Use cloud provider automated backups:
  • AWS RDS: Automated snapshots, point-in-time recovery
  • GCP Cloud SQL: Automated backups, replicas
  • Azure Database: Geo-redundant backups

Volume Snapshots

Disaster Recovery Plan

  1. Regular backups: Daily PostgreSQL dumps, hourly volume snapshots
  2. Multi-region replication: Replicate backups to separate region
  3. Test restores: Monthly restore tests to staging environment
  4. Documentation: Maintain runbook for recovery procedures
  5. Monitoring: Alert on backup failures

Monitoring and Observability

Prometheus Metrics

Enable Prometheus monitoring:

Logging

Centralized logging with ELK or Loki:

Alerting

Operations

Deployment Strategy

Rolling Updates

Blue-Green Deployment

Maintenance Windows

Database Migrations

Scaling Down for Maintenance

Cost Optimization

Use Managed Services

Replace in-cluster stateful services with managed alternatives:
  • Database: RDS, Cloud SQL, Azure Database (automated backups, HA)
  • Redis: ElastiCache, Memorystore, Azure Cache (managed persistence)
  • Object Storage: S3, GCS, Azure Blob (eliminate SeaweedFS)
  • Secrets: AWS Secrets Manager, GCP Secret Manager, Azure Key Vault

Resource Right-Sizing

Monitor actual usage and adjust:

Node Autoscaling

Checklist

Before going to production:
  • All secrets generated with openssl rand -base64 32
  • Vault configured with auto-unseal (cloud KMS)
  • TLS/HTTPS enabled with valid certificates
  • External object storage configured (S3, GCS, etc.)
  • Database backups configured and tested
  • Monitoring and alerting set up
  • Resource requests and limits configured
  • Replica counts set for HA (3+ for critical services)
  • NetworkPolicies applied
  • Pod isolation enabled (ENABLE_POD_ISOLATION=true)
  • Disaster recovery plan documented
  • Runbooks created for common operations
  • Rate limiting enabled
  • RBAC configured for team access
  • Log aggregation configured
  • Load testing performed

Next Steps

Scaling Guide

Scale Aurora for growing workloads

Monitoring Setup

Set up comprehensive monitoring

Backup & Recovery

Implement backup strategies

Troubleshooting

Common issues and solutions