Delete an Environment
Automatic Cleanup
Environments are deleted automatically when:
- The PR is merged — greyhound detects the merge event and cleans up
- The PR is closed — Closing without merging also triggers cleanup
- The deploy label is removed — Removing the label tells greyhound to tear down the environment
What Gets Cleaned Up
When an environment is deleted, greyhound removes:
- The Kubernetes namespace and all resources within it (pods, services, configmaps, secrets)
- Ingress rules and routing
- Aurora database clusters (returned to the pool or deleted)
- AWS infrastructure (security groups, IAM roles)
Environment TTL
Environments have a time-to-live (TTL). If an environment has been running longer than the configured TTL, greyhound's reaper workflow will clean it up automatically. This prevents forgotten environments from consuming resources indefinitely.