gitlab-org--gitlab-foss/lib/container_registry/config.rb

17 lines
257 B
Ruby
Raw Normal View History

module ContainerRegistry
class Config
attr_reader :tag, :blob, :data
def initialize(tag, blob)
@tag, @blob = tag, blob
@data = JSON.parse(blob.data)
end
def [](key)
return unless data
2016-05-17 10:41:47 -04:00
data[key]
end
end
end