Class: Kuby::Docker::Tags

Inherits:
Object
  • Object
show all
Defined in:
lib/kuby/docker/tags.rb

Constant Summary collapse

LATEST =
Metadata::LATEST_TAG

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(cli, remote_client, metadata) ⇒ Tags

Returns a new instance of Tags.



8
9
10
11
12
# File 'lib/kuby/docker/tags.rb', line 8

def initialize(cli, remote_client, )
  @cli = cli
  @remote_client = remote_client
  @metadata = 
end

Instance Attribute Details

#cliObject (readonly)

Returns the value of attribute cli.



6
7
8
# File 'lib/kuby/docker/tags.rb', line 6

def cli
  @cli
end

#metadataObject (readonly)

Returns the value of attribute metadata.



6
7
8
# File 'lib/kuby/docker/tags.rb', line 6

def 
  @metadata
end

#remote_clientObject (readonly)

Returns the value of attribute remote_client.



6
7
8
# File 'lib/kuby/docker/tags.rb', line 6

def remote_client
  @remote_client
end

Instance Method Details

#allObject



26
27
28
# File 'lib/kuby/docker/tags.rb', line 26

def all
  self
end

#latest_tagsObject



18
19
20
# File 'lib/kuby/docker/tags.rb', line 18

def latest_tags
  (local.latest_tags + remote.latest_tags).uniq
end

#localObject



30
31
32
# File 'lib/kuby/docker/tags.rb', line 30

def local
  @local ||= LocalTags.new(cli, )
end

#remoteObject



34
35
36
# File 'lib/kuby/docker/tags.rb', line 34

def remote
  @remote ||= RemoteTags.new(remote_client, )
end

#tagsObject



14
15
16
# File 'lib/kuby/docker/tags.rb', line 14

def tags
  (local.tags + remote.tags).uniq
end

#timestamp_tagsObject



22
23
24
# File 'lib/kuby/docker/tags.rb', line 22

def timestamp_tags
  (local.timestamp_tags + remote.timestamp_tags).uniq
end