Commit 543f657c authored by Drew Blessing's avatar Drew Blessing

Merge branch 'harish-and-cindy-ldap-sync-rake-tasks' into 'master'

LDAP rake task to run a GroupSync

Closes #13089

See merge request gitlab-org/gitlab-ee!14735
parents 4becfe5b 091c3b11
---
title: Add a rake task to run a LDAP group sync
merge_request: 14735
author: Harish Ramachandran and Cindy Pallares
type: added
namespace :gitlab do
namespace :ldap do
desc 'GitLab | LDAP | Run a GroupSync'
task group_sync: :gitlab_environment do
unless Gitlab::Auth::LDAP::Config.group_sync_enabled?
$stdout.puts 'LDAP GroupSync is not enabled.'
exit 1
end
$stdout.puts 'LDAP GroupSync is enabled.'
$stdout.puts 'Starting GroupSync...'
EE::Gitlab::Auth::LDAP::Sync::Groups.execute
$stdout.puts 'Finished GroupSync.'
end
end
end
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment