Class: Shippy::Cli::Prune

Inherits:
Base
  • Object
show all
Defined in:
lib/shippy/cli/prune.rb

Instance Method Summary collapse

Methods inherited from Base

exit_on_failure?, #initialize

Constructor Details

This class inherits a constructor from Shippy::Cli::Base

Instance Method Details

#all ⇒ Object



3
4
5
# File 'lib/shippy/cli/prune.rb', line 3

def all
  maintainer.clean_all
end

#containers ⇒ Object



16
17
18
19
# File 'lib/shippy/cli/prune.rb', line 16

def containers
  hours = options[:hours] || Shippy::Maintainer::CONTAINER_RETENTION_HOURS
  maintainer.clean_containers(hours: hours)
end

#images ⇒ Object



9
10
11
12
# File 'lib/shippy/cli/prune.rb', line 9

def images
  hours = options[:hours] || Shippy::Maintainer::IMAGE_RETENTION_HOURS
  maintainer.clean_images(hours: hours)
end