Skip to content

Instantly share code, notes, and snippets.

@benyanke
Created February 15, 2019 05:59
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Embed
What would you like to do?
This drops all the tables in elastic beanstalk
echo "SET FOREIGN_KEY_CHECKS = 0; `mysqldump --add-drop-table --no-data -h $RDS_HOSTNAME -u $RDS_USERNAME -p$RDS_PASSWORD $RDS_DB_NAME | grep 'DROP TABLE'` ;SET FOREIGN_KEY_CHECKS = 1;" | mysql -h $RDS_HOSTNAME -u $RDS_USERNAME -p$RDS_PASSWORD $RDS_DB_NAME
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment