How to unblock an LDAP blocked user in Gitlab
来源:互联网 发布:高校大数据实验室 编辑:程序博客网 时间:2024/05/19 23:54
It seems that if an LDAP user gets "LDAP blocked" intentionally or by some glitch in Gitlab then the user cannot be unblocked in the Web interface of Gitlab. This can be solved as follows on Linux.Log onto your Linux that hosts your Gitlab, become root, and execute the following commands:su gitcd ~/gitlabbundle exec rails c productionBefore the command "bundle exec rails c production", you may need to add the location of the file "bundle" to the variable PATH. For example, you may need to executeexport PATH=$PATH:/usr/local/binif the file "bundle" is in the directory /usr/local/bin.Wait for the start of "bundle exec rails c production" and appearance of the command prompt ">". In the appeared CLI, execute the following commands:user = User.find_by_email("myuser@example.com")user.state = "active"user.saveexitUse the real email address of the user in Gitlab instead of myuser@example.com.I found this solution and posted on https://gitlab.com/gitlab-org/gitlab-ce/issues/13179.
我的步骤:
1. su git
2. cd /opt/gitlab/embedded/service/gitlab-rails3. export PATH=$PATH:/opt/gitlab/embedded/bin/
4. bundle exec rails c production
user = User.find_by_email("xxx@xxxx.com")
user.state = "active"
user.save
exit
1 0
- How to unblock an LDAP blocked user in Gitlab
- How to resolve "your security settings have blocked an untrusted application from running" in Mac
- How to get all the members in user group by using LDAP in Perl?
- How to integrate LDAP in Perl?
- How To Use the GitLab User Interface To Manage Projects
- How to properly unblock libusb_bulk_transfer
- How to allow a user to click on TextBlocks which return an integer ID in the click handler
- How to create a user in PostgreSQL
- How to active 'root' user in ubuntu
- How to Change Login User in SharePoint2013?
- How to unlock user in DB
- How to add user in gerrit
- An Introduction to LDAP
- An Introduction to LDAP
- How to choose an in-circuit emulator
- How to define an array in c#.
- How to inherit an Object in JavaScript
- How to initialize an array in C
- 数据结构实验之二叉树二:遍历二叉树
- 家用漏电开关跳闸的原因
- CF#367(Div2)D. Vasiliy's Multiset (字典树)
- Struts 2
- redis(2.8)配置文件参数详解
- How to unblock an LDAP blocked user in Gitlab
- Fragment嵌套Fragment产生的问题
- 【杂谈】腾讯面试杂谈
- 2070 Fibbonacci Number
- 【BLE-CC2640】CC2640之快速入门
- wget 用法
- 文件上传
- iOS视频直播:高仿<喵播APP>
- Zookeeper入门指南中文版