<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>

                ThinkChat2.0新版上線,更智能更精彩,支持會話、畫圖、視頻、閱讀、搜索等,送10W Token,即刻開啟你的AI之旅 廣告
                # GitLab Package Registry administration > 原文:[https://docs.gitlab.com/ee/administration/packages/](https://docs.gitlab.com/ee/administration/packages/) * [Enabling the Packages feature](#enabling-the-packages-feature) * [Changing the storage path](#changing-the-storage-path) * [Changing the local storage path](#changing-the-local-storage-path) * [Using object storage](#using-object-storage) * [Migrating local packages to object storage](#migrating-local-packages-to-object-storage) # GitLab Package Registry administration[](#gitlab-package-registry-administration-premium-only "Permalink") GitLab 軟件包允許組織將 GitLab 用作各種常見軟件包管理器的私有存儲庫. 用戶能夠構建和發布程序包,這些程序包可以很容易地作為下游項目中的依賴項使用. 軟件包功能允許 GitLab 充當以下內容的存儲庫: | 軟件庫 | Description | 在 GitLab 版本中可用 | | --- | --- | --- | | [PyPi Repository](../../user/packages/pypi_repository/index.html) | GitLab PyPi 存儲庫使 GitLab 中的每個項目都有自己的空間來存儲[PyPi](https://s0pypi0org.icopy.site/)軟件包. | 12.10+ | | [Composer Repository](../../user/packages/composer_repository/index.html) | GitLab Composer 存儲庫使 GitLab 中的每個項目都有自己的空間來存儲[Composer](https://s0getcomposer0org.icopy.site/)軟件包. | 13.1+ | | [NuGet Repository](../../user/packages/nuget_repository/index.html) | GitLab NuGet 存儲庫使 GitLab 中的每個項目都有自己的空間來存儲[NuGet](https://www.nuget.org/)軟件包. | 12.8+ | | [Conan Repository](../../user/packages/conan_repository/index.html) | GitLab 柯南存儲庫使 GitLab 中的每個項目都有自己的空間來存儲[柯南](https://conan.io/)軟件包. | 12.4+ | | [Maven Repository](../../user/packages/maven_repository/index.html) | GitLab Maven 存儲庫使 GitLab 中的每個項目都有自己的空間來存儲[Maven](https://maven.apache.org/)軟件包. | 11.3+ | | [NPM Registry](../../user/packages/npm_registry/index.html) | GitLab NPM 注冊表使 GitLab 中的每個項目都有自己的空間來存儲[NPM](https://s0www0npmjs0com.icopy.site/)軟件包. | 11.7+ | | [Go Proxy](../../user/packages/go_proxy/index.html) | GitLab 的 Go 代理使 GitLab 中的每個項目都可以通過[Go 代理協議](https://proxy.golang.org/)獲取. | 13.1+ | 您沒有看到您的包裹管理系統受支持嗎? 請考慮為 GitLab 做貢獻. 此[開發文檔](../../development/packages.html)將指導您完成該過程. ## Enabling the Packages feature[](#enabling-the-packages-feature "Permalink") **注意:**啟用"軟件包"功能后,默認情況下,存儲庫可用于所有新項目. 要為現有項目啟用它,用戶將必須在項目的設置中明確啟用它. 要啟用包功能: **所有裝置 GitLab** 1. 編輯`/etc/gitlab/gitlab.rb`并添加以下行: ``` gitlab_rails['packages_enabled'] = true ``` 2. 保存文件并[重新配置 GitLab,](../restart_gitlab.html#omnibus-gitlab-reconfigure "如何重新配置??Omnibus GitLab")以使更改生效. **從源安裝** 1. 安裝完成后,您將必須在`config/gitlab.yml`中`config/gitlab.yml` `packages`部分. 設置為`true`以啟用它: ``` packages: enabled: true ``` 2. [重新啟動 GitLab,](../restart_gitlab.html#omnibus-gitlab-reconfigure "如何重新配置??Omnibus GitLab")以使更改生效. ## Changing the storage path[](#changing-the-storage-path "Permalink") 默認情況下,程序包存儲在本地,但是您可以更改默認的本地位置,甚至使用對象存儲. ### Changing the local storage path[](#changing-the-local-storage-path "Permalink") 用于 Omnibus GitLab 安裝的軟件包存儲在`/var/opt/gitlab/gitlab-rails/shared/packages/`而用于源安裝的`shared/packages/`在`shared/packages/` (相對于 Git 主目錄). 更改本地存儲路徑: **所有裝置 GitLab** 1. 編輯`/etc/gitlab/gitlab.rb`并添加以下行: ``` gitlab_rails['packages_storage_path'] = "/mnt/packages" ``` 2. 保存文件并[重新配置 GitLab,](../restart_gitlab.html#omnibus-gitlab-reconfigure)以使更改生效. **從源安裝** 1. 編輯`config/gitlab.yml`的`packages`部分: ``` packages: enabled: true storage_path: shared/packages ``` 2. 保存文件并[重新啟動 GitLab,](../restart_gitlab.html#installations-from-source)以使更改生效. ### Using object storage[](#using-object-storage "Permalink") 您可以使用對象存儲來存儲程序包,而不必依賴于本地存儲. [Read more about using object storage with GitLab](../object_storage.html). **注意:**我們建議使用[統一對象存儲設置](../object_storage.html#consolidated-object-storage-configuration) . 以下說明適用于原始配置格式. **Omnibus GitLab installations** 1. 編輯`/etc/gitlab/gitlab.rb`并添加以下行(必要時取消注釋): ``` gitlab_rails['packages_enabled'] = true gitlab_rails['packages_storage_path'] = "/var/opt/gitlab/gitlab-rails/shared/packages" gitlab_rails['packages_object_store_enabled'] = true gitlab_rails['packages_object_store_remote_directory'] = "packages" # The bucket name. gitlab_rails['packages_object_store_direct_upload'] = false # Use Object Storage directly for uploads instead of background uploads if enabled (Default: false). gitlab_rails['packages_object_store_background_upload'] = true # Temporary option to limit automatic upload (Default: true). gitlab_rails['packages_object_store_proxy_download'] = false # Passthrough all downloads via GitLab instead of using Redirects to Object Storage. gitlab_rails['packages_object_store_connection'] = { ## ## If the provider is AWS S3, uncomment the following ## #'provider' => 'AWS', #'region' => 'eu-west-1', #'aws_access_key_id' => 'AWS_ACCESS_KEY_ID', #'aws_secret_access_key' => 'AWS_SECRET_ACCESS_KEY', ## ## If the provider is other than AWS (an S3-compatible one), uncomment the following ## #'host' => 's3.amazonaws.com', #'aws_signature_version' => 4 # For creation of signed URLs. Set to 2 if provider does not support v4. #'endpoint' => 'https://s3.amazonaws.com' # Useful for S3-compliant services such as DigitalOcean Spaces. #'path_style' => false # If true, use 'host/bucket_name/object' instead of 'bucket_name.host/object'. } ``` 2. 保存文件并[重新配置 GitLab,](../restart_gitlab.html#omnibus-gitlab-reconfigure)以使更改生效. **從源安裝** 1. 編輯`config/gitlab.yml`的`packages`部分(必要時取消注釋): ``` packages: enabled: true ## ## The location where build packages are stored (default: shared/packages). ## #storage_path: shared/packages object_store: enabled: false remote_directory: packages # The bucket name. #direct_upload: false # Use Object Storage directly for uploads instead of background uploads if enabled (Default: false). #background_upload: true # Temporary option to limit automatic upload (Default: true). #proxy_download: false # Passthrough all downloads via GitLab instead of using Redirects to Object Storage. connection: ## ## If the provider is AWS S3, uncomment the following ## #provider: AWS #region: us-east-1 #aws_access_key_id: AWS_ACCESS_KEY_ID #aws_secret_access_key: AWS_SECRET_ACCESS_KEY ## ## If the provider is other than AWS (an S3-compatible one), uncomment the following ## #host: 's3.amazonaws.com' # default: s3.amazonaws.com. #aws_signature_version: 4 # For creation of signed URLs. Set to 2 if provider does not support v4. #endpoint: 'https://s3.amazonaws.com' # Useful for S3-compliant services such as DigitalOcean Spaces. #path_style: false # If true, use 'host/bucket_name/object' instead of 'bucket_name.host/object'. ``` 2. 保存文件并[重新啟動 GitLab,](../restart_gitlab.html#installations-from-source)以使更改生效. ### Migrating local packages to object storage[](#migrating-local-packages-to-object-storage "Permalink") [配置對象存儲后](#using-object-storage) ,您可以使用以下任務將現有程序包從本地存儲遷移到遠程存儲. 該處理將在后臺工作人員中完成, **無需停機** . 對于所有 GitLab; ``` sudo gitlab-rake "gitlab:packages:migrate" ``` 對于源安裝: ``` RAILS_ENV=production sudo -u git -H bundle exec rake gitlab:packages:migrate ```
                  <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>

                              哎呀哎呀视频在线观看