Skip to content

Instantly share code, notes, and snippets.

@sadok-f
Last active January 11, 2019 18:42
Show Gist options
  • Select an option

  • Save sadok-f/20b6c4ad111a8f263468ccc18df7392a to your computer and use it in GitHub Desktop.

Select an option

Save sadok-f/20b6c4ad111a8f263468ccc18df7392a to your computer and use it in GitHub Desktop.
Gitlab: Disable groups creation
# Edit etc/gitlab/gitlab.rb
gitlab_rails['gitlab_default_can_create_group'] = false
# Restart gitlab:
gitlab-ctl reconfigure
gitlab-ctl restart
# Update current users' settings:
gitlab-rails console production
-->
for user in User.where(can_create_group: true) do
user.can_create_group= false
user.save!
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment