Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
5ba3a3f2
Commit
5ba3a3f2
authored
Jun 06, 2017
by
Robin Bobbitt
Committed by
Bob Van Landuyt
Jun 08, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Sync email address from specified omniauth provider - db changes
parent
7390772c
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
42 additions
and
2 deletions
+42
-2
db/migrate/20170531202042_rename_users_ldap_email_to_external_email.rb
...170531202042_rename_users_ldap_email_to_external_email.rb
+15
-0
db/migrate/20170603200744_add_email_provider_to_users.rb
db/migrate/20170603200744_add_email_provider_to_users.rb
+9
-0
db/post_migrate/20170531203055_cleanup_users_ldap_email_rename.rb
...migrate/20170531203055_cleanup_users_ldap_email_rename.rb
+15
-0
db/schema.rb
db/schema.rb
+3
-2
No files found.
db/migrate/20170531202042_rename_users_ldap_email_to_external_email.rb
0 → 100644
View file @
5ba3a3f2
class
RenameUsersLdapEmailToExternalEmail
<
ActiveRecord
::
Migration
include
Gitlab
::
Database
::
MigrationHelpers
DOWNTIME
=
false
disable_ddl_transaction!
def
up
rename_column_concurrently
:users
,
:ldap_email
,
:external_email
end
def
down
cleanup_concurrent_column_rename
:users
,
:external_email
,
:ldap_email
end
end
db/migrate/20170603200744_add_email_provider_to_users.rb
0 → 100644
View file @
5ba3a3f2
class
AddEmailProviderToUsers
<
ActiveRecord
::
Migration
include
Gitlab
::
Database
::
MigrationHelpers
DOWNTIME
=
false
def
change
add_column
:users
,
:email_provider
,
:string
end
end
db/post_migrate/20170531203055_cleanup_users_ldap_email_rename.rb
0 → 100644
View file @
5ba3a3f2
class
CleanupUsersLdapEmailRename
<
ActiveRecord
::
Migration
include
Gitlab
::
Database
::
MigrationHelpers
DOWNTIME
=
false
disable_ddl_transaction!
def
up
cleanup_concurrent_column_rename
:users
,
:ldap_email
,
:external_email
end
def
down
rename_column_concurrently
:users
,
:external_email
,
:ldap_email
end
end
db/schema.rb
View file @
5ba3a3f2
...
...
@@ -11,7 +11,7 @@
#
# It's strongly recommended that you check this file into your version control system.
ActiveRecord
::
Schema
.
define
(
version:
2017060
200330
4
)
do
ActiveRecord
::
Schema
.
define
(
version:
2017060
320074
4
)
do
# These are extensions that must be enabled in order to support this database
enable_extension
"plpgsql"
...
...
@@ -1640,7 +1640,6 @@ ActiveRecord::Schema.define(version: 20170602003304) do
t
.
text
"note"
t
.
string
"unlock_token"
t
.
datetime
"otp_grace_period_started_at"
t
.
boolean
"ldap_email"
,
default:
false
,
null:
false
t
.
boolean
"external"
,
default:
false
t
.
string
"incoming_email_token"
t
.
string
"organization"
...
...
@@ -1653,6 +1652,8 @@ ActiveRecord::Schema.define(version: 20170602003304) do
t
.
boolean
"support_bot"
t
.
string
"preferred_language"
t
.
string
"rss_token"
t
.
boolean
"external_email"
,
default:
false
,
null:
false
t
.
string
"email_provider"
end
add_index
"users"
,
[
"admin"
],
name:
"index_users_on_admin"
,
using: :btree
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment