class Vpsb::Commands::Setup

Attributes

core[R]

Public Class Methods

new(core) click to toggle source
# File lib/vpsb/commands/setup.rb, line 7
def initialize(core)
  @core = core
end

Public Instance Methods

execute(params) click to toggle source
# File lib/vpsb/commands/setup.rb, line 11
def execute(params)
  unless File.exist?(core.get(:knife_rb_path))
    return puts "You did not run init script, because i cannot find knife.rb file in bootstrap server app. ;)"
  end

  Vpsb::Tasks::DoApiAccess.new(core).call
  Vpsb::Tasks::DropletSshKeys.new(core).call
  Vpsb::Tasks::CreateDroplet.new(core).call
  Vpsb::Tasks::DropletSshUpdateConfig.new(core).call
end