Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'doc/administration/packages/container_registry.md')
-rw-r--r--doc/administration/packages/container_registry.md51
1 files changed, 51 insertions, 0 deletions
diff --git a/doc/administration/packages/container_registry.md b/doc/administration/packages/container_registry.md
index 33a5311709f..7bf7362c68b 100644
--- a/doc/administration/packages/container_registry.md
+++ b/doc/administration/packages/container_registry.md
@@ -457,6 +457,22 @@ To configure the `s3` storage driver in Omnibus:
- `pathstyle` should be set to true to use `host/bucket_name/object` style paths instead of
`bucket_name.host/object`. [Set to false for AWS S3](https://aws.amazon.com/blogs/aws/amazon-s3-path-deprecation-plan-the-rest-of-the-story/).
+ You can set a rate limit on connections to S3 to avoid 503 errors from the S3 API. To do this,
+ set `maxrequestspersecond` to a number within the [S3 request rate threshold](https://aws.amazon.com/premiumsupport/knowledge-center/s3-503-within-request-rate-prefix/):
+
+ ```ruby
+ registry['storage'] = {
+ 's3' => {
+ 'accesskey' => 's3-access-key',
+ 'secretkey' => 's3-secret-key-for-access-key',
+ 'bucket' => 'your-s3-bucket',
+ 'region' => 'your-s3-region',
+ 'regionendpoint' => 'your-s3-regionendpoint',
+ 'maxrequestspersecond' => 100
+ }
+ }
+ ```
+
1. Save the file and [reconfigure GitLab](../restart_gitlab.md#omnibus-gitlab-reconfigure) for the changes to take effect.
**Installations from source**
@@ -1704,3 +1720,38 @@ What does this mean? This strongly suggests that the S3 user does not have the r
[permissions to perform a HEAD request](https://docs.aws.amazon.com/AmazonS3/latest/API/API_HeadObject.html).
The solution: check the [IAM permissions again](https://docs.docker.com/registry/storage-drivers/s3/).
Once the right permissions were set, the error goes away.
+
+### Missing `gitlab-registry.key` prevents container repository deletion
+
+If you disable your GitLab instance's Container Registry and try to remove a project that has
+container repositories, the following error occurs:
+
+```plaintext
+Errno::ENOENT: No such file or directory @ rb_sysopen - /var/opt/gitlab/gitlab-rails/etc/gitlab-registry.key
+```
+
+In this case, follow these steps:
+
+1. Temporarily enable the instance-wide setting for the Container Registry in your `gitlab.rb`:
+
+ ```ruby
+ gitlab_rails['registry_enabled'] = true
+ ```
+
+1. Save the file and [reconfigure GitLab](../restart_gitlab.md#omnibus-gitlab-reconfigure)
+ for the changes to take effect.
+1. Try the removal again.
+
+If you still can't remove the repository using the common methods, you can use the
+[GitLab Rails console](../troubleshooting/navigating_gitlab_via_rails_console.md)
+to remove the project by force:
+
+```ruby
+# Path to the project you'd like to remove
+prj = Project.find_by_full_path(<project_path>)
+
+# The following will delete the project's container registry, so be sure to double-check the path beforehand!
+if prj.has_container_registry_tags?
+ prj.container_repositories.each { |p| p.destroy }
+end
+```