Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Paste
P16962
create a gitlab admin
Active
Public
Actions
Authored by
brennen
on Aug 5 2021, 3:56 PM.
Edit Paste
Archive Paste
View Raw File
Subscribe
Mute Notifications
Award Token
Flag For Later
Tags
None
Referenced Files
F34585427: create a gitlab admin
Aug 5 2021, 3:56 PM
2021-08-05 15:56:56 (UTC+0)
Subscribers
Jelto
== set a user as admin ==
{{{sh
# This will take a long time to load, just wait:
sudo gitlab-rails console
}}}
{{{ruby
irb(main):023:0> u = User.find_by_username('Thcipriani')
=> #<User id:7 @thcipriani>
irb(main):025:0> u.admin = true
=> true
irb(main):026:0> u.save!
}}}
Event Timeline
brennen
created this paste.
Aug 5 2021, 3:56 PM
2021-08-05 15:56:56 (UTC+0)
Jelto
added a subscriber:
Jelto
.
Aug 6 2021, 7:32 AM
2021-08-06 07:32:07 (UTC+0)
Log In to Comment