Sha256: f1a339e4d30e29e50f407ca8d621cf61ce7d41e0e910450111bd1e0a6174469a
Contents?: true
Size: 1.09 KB
Versions: 19
Compression:
Stored size: 1.09 KB
Contents
module Katello module Pulp3 class DockerManifest < PulpContentUnit include LazyAccessor CONTENT_TYPE = "docker_manifest".freeze def self.content_api PulpContainerClient::ContentManifestsApi.new(Katello::Pulp3::Api::Docker.new(SmartProxy.pulp_primary!).api_client) end def self.ids_for_repository(repo_id) repo = Katello::Pulp3::Repository::Docker.new(Katello::Repository.find(repo_id), SmartProxy.pulp_primary) repo_content_list = repo.content_list repo_content_list.map { |content| content.try(:pulp_href) } end def self.content_unit_list(page_opts) page_opts[:media_type] = ['application/vnd.docker.distribution.manifest.v1+json', 'application/vnd.docker.distribution.manifest.v2+json'] self.content_api.list(page_opts) end def update_model(model) custom_json = {} custom_json['schema_version'], = backend_data['schema_version'] custom_json['digest'], = backend_data['digest'] model.update!(custom_json) end end end end
Version data entries
19 entries across 19 versions & 1 rubygems