summaryrefslogtreecommitdiff
path: root/db/migrate
diff options
context:
space:
mode:
authorDouwe Maan <douwe@selenight.nl>2016-08-19 18:33:46 -0500
committertiagonbotelho <tiagonbotelho@hotmail.com>2016-11-07 15:55:42 +0000
commit9d51421346178c9189ffb47189f51d573ab42822 (patch)
tree4990e9766af58e9dfc687f5451c6efe36fdbebcd /db/migrate
parent09f4af04c6672f7e2d1584f9940a3d9ff53a4a4f (diff)
downloadgitlab-ce-9d51421346178c9189ffb47189f51d573ab42822.tar.gz
Use separate email-friendly token for incoming email and let incoming
email token be reset
Diffstat (limited to 'db/migrate')
-rw-r--r--db/migrate/20160819232256_add_incoming_email_token_to_users.rb16
1 files changed, 16 insertions, 0 deletions
diff --git a/db/migrate/20160819232256_add_incoming_email_token_to_users.rb b/db/migrate/20160819232256_add_incoming_email_token_to_users.rb
new file mode 100644
index 00000000000..f2cf956adc9
--- /dev/null
+++ b/db/migrate/20160819232256_add_incoming_email_token_to_users.rb
@@ -0,0 +1,16 @@
+# See http://doc.gitlab.com/ce/development/migration_style_guide.html
+# for more information on how to write migrations for GitLab.
+
+class AddIncomingEmailTokenToUsers < ActiveRecord::Migration
+ include Gitlab::Database::MigrationHelpers
+
+ # Set this constant to true if this migration requires downtime.
+ DOWNTIME = false
+
+ disable_ddl_transaction!
+
+ def change
+ add_column :users, :incoming_email_token, :string
+ add_concurrent_index :users, :incoming_email_token
+ end
+end