diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2023-12-22 18:12:49 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2023-12-22 18:12:49 +0300 |
commit | c60010859638f577dab891358e83945561b35ad2 (patch) | |
tree | 6badf09d24d14aa03bf265f4ba7dcc368ac9fa78 /lib/container_registry/tag.rb | |
parent | 26fa51816ab94df9c2f3db8c93da4d57f7bd6fc4 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'lib/container_registry/tag.rb')
-rw-r--r-- | lib/container_registry/tag.rb | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/container_registry/tag.rb b/lib/container_registry/tag.rb index 70742e8bd38..0000a0641be 100644 --- a/lib/container_registry/tag.rb +++ b/lib/container_registry/tag.rb @@ -4,7 +4,7 @@ module ContainerRegistry class Tag include Gitlab::Utils::StrongMemoize - attr_reader :repository, :name, :updated_at + attr_reader :repository, :name, :updated_at, :referrers attr_writer :created_at, :manifest_digest, :revision, :total_size delegate :registry, :client, to: :repository @@ -14,6 +14,10 @@ module ContainerRegistry @name = name end + def referrers=(refs) + @referrers = Array.wrap(refs).map { |ref| Referrer.new(ref['artifactType'], ref['digest'], self) } + end + def revision @revision || config_blob&.revision end |