Class: GrokCLI::Docker::WordPress::Destroy
- Inherits:
-
Object
- Object
- GrokCLI::Docker::WordPress::Destroy
- Defined in:
- lib/grok_cli/docker/wordpress/destroy.rb
Instance Method Summary collapse
- #execute ⇒ Object
-
#initialize(config = GrokCLI::Docker::Configuration.new) ⇒ Destroy
constructor
A new instance of Destroy.
Constructor Details
#initialize(config = GrokCLI::Docker::Configuration.new) ⇒ Destroy
Returns a new instance of Destroy.
3 4 5 |
# File 'lib/grok_cli/docker/wordpress/destroy.rb', line 3 def initialize(config = GrokCLI::Docker::Configuration.new) @config = config end |
Instance Method Details
#execute ⇒ Object
7 8 9 10 11 12 13 14 15 16 |
# File 'lib/grok_cli/docker/wordpress/destroy.rb', line 7 def execute system <<~CMD docker-machine create #{@config.machine_name} --driver virtualbox eval "$(docker-machine env #{@config.machine_name})" docker-compose down CMD end |