<ruby id="bdb3f"></ruby>

    <p id="bdb3f"><cite id="bdb3f"></cite></p>

      <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
        <p id="bdb3f"><cite id="bdb3f"></cite></p>

          <pre id="bdb3f"></pre>
          <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

          <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
          <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

          <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                <ruby id="bdb3f"></ruby>

                合規國際互聯網加速 OSASE為企業客戶提供高速穩定SD-WAN國際加速解決方案。 廣告
                # LDAP Rake tasks > 原文:[https://docs.gitlab.com/ee/administration/raketasks/ldap.html](https://docs.gitlab.com/ee/administration/raketasks/ldap.html) * [Check](#check) * [Run a group sync](#run-a-group-sync-starter-only) * [Rename a provider](#rename-a-provider) * [Example](#example) * [Other options](#other-options) # LDAP Rake tasks[](#ldap-rake-tasks-core-only "Permalink") 以下是與 LDAP 相關的 Rake 任務. ## Check[](#check "Permalink") LDAP 檢查 Rake 任務將測試`bind_dn`和`password`憑據(如果已配置),并將列出 LDAP 用戶的樣本. 此任務也作為`gitlab:check`任務的一部分執行,但可以使用以下命令獨立運行. **全部安裝** ``` sudo gitlab-rake gitlab:ldap:check ``` **源安裝** ``` sudo -u git -H bundle exec rake gitlab:ldap:check RAILS_ENV=production ``` 默認情況下,該任務將返回 100 個 LDAP 用戶的樣本. 通過將數字傳遞給檢查任務來更改此限制: ``` rake gitlab:ldap:check[50] ``` ## Run a group sync[](#run-a-group-sync-starter-only "Permalink") [Introduced](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/14735) in [GitLab Starter](https://about.gitlab.com/pricing/) 12.2. The following task will run a [group sync](../auth/ldap/index.html#group-sync-starter-only) immediately. This is valuable when you’d like to update all configured group memberships against LDAP without waiting for the next scheduled group sync to be run. **注意:**如果您想更改執行群組同步的頻率,請改為[調整 Cron 時間表](../auth/ldap/index.html#adjusting-ldap-group-sync-schedule-starter-only) . **全部安裝** ``` sudo gitlab-rake gitlab:ldap:group_sync ``` **源安裝** ``` bundle exec rake gitlab:ldap:group_sync ``` ## Rename a provider[](#rename-a-provider "Permalink") 如果您在`gitlab.yml`或`gitlab.rb`更改 LDAP 服務器 ID,則將需要更新所有用戶身份,否則用戶將無法登錄.輸入新舊提供者,此任務將更新數據庫中所有匹配的身份. `old_provider`和`new_provider`是從前綴`ldap`加上配置文件中的 LDAP 服務器 ID 派生的. 例如,在`gitlab.yml`或`gitlab.rb`您可能會看到 LDAP 配置,如下所示: ``` main: label: 'LDAP' host: '_your_ldap_server' port: 389 uid: 'sAMAccountName' ... ``` `main`是 LDAP 服務器 ID. 唯一的提供者在一起就是`ldapmain` . > **警告** :如果輸入了錯誤的新提供程序,用戶將無法登錄.如果發生這種情況,請使用錯誤的提供程序作為`old_provider`并使用正確的提供程序作為`new_provider`再次運行任務. **全部安裝** ``` sudo gitlab-rake gitlab:ldap:rename_provider[old_provider,new_provider] ``` **源安裝** ``` bundle exec rake gitlab:ldap:rename_provider[old_provider,new_provider] RAILS_ENV=production ``` ### Example[](#example "Permalink") 考慮從默認服務器 ID `main` (完整提供程序`ldapmain` )開始. 如果將`main`更改為`mycompany` ,則`new_provider`為`ldapmycompany` . 要重命名所有用戶身份,請運行以下命令: ``` sudo gitlab-rake gitlab:ldap:rename_provider[ldapmain,ldapmycompany] ``` 輸出示例: ``` 100 users with provider 'ldapmain' will be updated to 'ldapmycompany'. If the new provider is incorrect, users will be unable to sign in. Do you want to continue (yes/no)? yes User identities were successfully updated ``` ### Other options[](#other-options "Permalink") 如果您未指定`old_provider`和`new_provider` ,則會提示您輸入它們: **全部安裝** ``` sudo gitlab-rake gitlab:ldap:rename_provider ``` **源安裝** ``` bundle exec rake gitlab:ldap:rename_provider RAILS_ENV=production ``` **輸出示例:** ``` What is the old provider? Ex. 'ldapmain': ldapmain What is the new provider? Ex. 'ldapcustom': ldapmycompany ``` 此任務還接受`force`環境變量,該變量將跳過確認對話框: ``` sudo gitlab-rake gitlab:ldap:rename_provider[old_provider,new_provider] force=yes ```
                  <ruby id="bdb3f"></ruby>

                  <p id="bdb3f"><cite id="bdb3f"></cite></p>

                    <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
                      <p id="bdb3f"><cite id="bdb3f"></cite></p>

                        <pre id="bdb3f"></pre>
                        <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

                        <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
                        <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

                        <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                              <ruby id="bdb3f"></ruby>

                              哎呀哎呀视频在线观看