Class: Vpsb::Commands::Deploy

Inherits:
Object
  • Object
show all
Includes:
AskSupport
Defined in:
lib/vpsb/commands/deploy.rb

Instance Method Summary collapse

Methods included from AskSupport

#ask, #ask_loop, #ask_to_confirm

Constructor Details

#initialize(core) ⇒ Deploy

Returns a new instance of Deploy.



5
6
7
# File 'lib/vpsb/commands/deploy.rb', line 5

def initialize(core)
  @core = core
end

Instance Method Details

#execute(params) ⇒ Object



9
10
11
12
13
14
15
# File 'lib/vpsb/commands/deploy.rb', line 9

def execute(params)

  Vpsb::Tasks::DeployConfig.new(core).call
  puts "Start deploying app."
  run(core.get(:rails_app_path), 'bundle exec cap production deploy')
  puts "app is ready! Visit #{core.get(:do_host_ip)}"
end