Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYorick Peterse <yorickpeterse@gmail.com>2017-11-17 13:09:20 +0300
committerYorick Peterse <yorickpeterse@gmail.com>2017-11-17 13:09:20 +0300
commitc07c6a5f075c69cda894ddd35b808fa1dc8bf85f (patch)
tree6e3cfce92b8ac8cdc1b57a36ddef1845963f6c73
parent128cb03bc861580f7bbe3724bf65c00e7806e09c (diff)
parentc99d58307b912aa7d3b8fdd39d8a44f639be2682 (diff)
Merge branch 'mk-update-database-debugging' into 'master'
Update database_debugging.md See merge request gitlab-org/gitlab-ce!15434
-rw-r--r--doc/development/database_debugging.md15
1 files changed, 11 insertions, 4 deletions
diff --git a/doc/development/database_debugging.md b/doc/development/database_debugging.md
index e1c785d85fa..50eb8005b44 100644
--- a/doc/development/database_debugging.md
+++ b/doc/development/database_debugging.md
@@ -9,17 +9,24 @@ An easy first step is to search for your error in Slack or google "GitLab <my er
Available `RAILS_ENV`
+ - `production` (generally not for your main GDK db, but you may need this for e.g. omnibus)
- `development` (this is your main GDK db)
- `test` (used for tests like rspec and spinach)
## Nuke everything and start over
-If you just want to delete everything and start over,
+If you just want to delete everything and start over with an empty DB (~1 minute):
- - `bundle exec rake dev:setup RAILS_ENV=development` : Also runs DB specific stuff and seeds dummy data (slow)
- - `bundle exec rake db:reset RAILS_ENV=development` : Doesn't do the above (fast)
- - `bundle exec rake db:reset RAILS_ENV=test` : Fix the test DB, since it doesn't contain important data.
+ - `bundle exec rake db:reset RAILS_ENV=development`
+
+If you just want to delete everything and start over with dummy data (~40 minutes). This also does `db:reset` and runs DB-specific migrations:
+
+ - `bundle exec rake dev:setup RAILS_ENV=development`
+
+If your test DB is giving you problems, it is safe to nuke it because it doesn't contain important data:
+
+ - `bundle exec rake db:reset RAILS_ENV=test`
## Migration wrangling