Class: Aircon::Commands::Down
- Inherits:
-
Object
- Object
- Aircon::Commands::Down
- Defined in:
- lib/aircon/commands/down.rb
Instance Method Summary collapse
- #call(name) ⇒ Object
-
#initialize(config:) ⇒ Down
constructor
A new instance of Down.
Constructor Details
#initialize(config:) ⇒ Down
Returns a new instance of Down.
6 7 8 |
# File 'lib/aircon/commands/down.rb', line 6 def initialize(config:) @config = config end |
Instance Method Details
#call(name) ⇒ Object
10 11 12 13 14 |
# File 'lib/aircon/commands/down.rb', line 10 def call(name) puts "Tearing down containers for '#{name}'..." system("docker", "compose", "-p", name, "down", "-v", "--remove-orphans") system("docker", "image", "prune", "-f") end |