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 'lib/tasks/gitlab/container_registry.rake')
-rw-r--r--lib/tasks/gitlab/container_registry.rake16
1 files changed, 1 insertions, 15 deletions
diff --git a/lib/tasks/gitlab/container_registry.rake b/lib/tasks/gitlab/container_registry.rake
index 7687cb237cc..cd18c873a5a 100644
--- a/lib/tasks/gitlab/container_registry.rake
+++ b/lib/tasks/gitlab/container_registry.rake
@@ -15,21 +15,7 @@ namespace :gitlab do
warn_user_is_not_gitlab
- url = registry_config.api_url
- # registry_info will query the /v2 route of the registry API. This route
- # requires authentication, but not authorization (the response has no body,
- # only headers that show the version of the registry). There is no
- # associated user when running this rake, so we need to generate a valid
- # JWT token with no access permissions to authenticate as a trusted client.
- token = Auth::ContainerRegistryAuthenticationService.access_token([], [])
- client = ContainerRegistry::Client.new(url, token: token)
- info = client.registry_info
-
- Gitlab::CurrentSettings.update!(
- container_registry_vendor: info[:vendor] || '',
- container_registry_version: info[:version] || '',
- container_registry_features: info[:features] || []
- )
+ UpdateContainerRegistryInfoService.new.execute
end
end
end