We deleted the production database by accident
keepthescore.co
We deleted the production database by accident
1–10 of 456 posts
Re: We deleted the production database by accident
#2Re: We deleted the production database by accident
#3Re: We deleted the production database by accident
#4Re: We deleted the production database by accident
#5Re: We deleted the production database by accident
#6Re: We deleted the production database by accident
#7Obviously, somehow the script ran on the database host.
some practices I've followed in the past to keep this kind of thing from happening:
* A script that deletes all the data can never be deployed to production.
* scripts that alter the DB rename tables/columns rather than dropping them (you write a matching rollback script ), for at least one schema upgrade cycle. you can always restore from backups, but this can make rollbacks quick when you spot a problem at deployment time.
* the number of people with access to the database in prod is severely restricted. I suppose this is obvious, so I'm curious how the particular chain of events in TFA happened.
Re: We deleted the production database by accident
#8SSH tunnel from localhost to prod on database port?
Re: We deleted the production database by accident
#9LOL, I forgot how few safety measure startups have in place.
Re: We deleted the production database by accident
#10Whoa.