Deleting the database
The database is not automatically removed when deleting your NAIS application. Remove unused databases to avoid incurring unnecessary costs. This is done by setting cascadingDelete in your nais.yaml
-specification.
Danger
When you delete an Cloud SQL instance, you cannot reuse the name of the deleted instance until one week from the deletion date.
To remove a database completely without deleting the application:
- First, set cascadingDelete to
true
in the application spec and deploy it - Remove
sqlInstances
from the application spec and deploy again
The database and the instance it runs on should now be completely removed after a short while.