Sha256: 291de38acddb597538c68db5e68407a0c0d0eff531f01ddc4c37f9ffaaaf54b9

Contents?: true

Size: 524 Bytes

Versions: 7

Compression:

Stored size: 524 Bytes

Contents

module Vpsb
  module Commands
    class Deploy
      include AskSupport
      def initialize(core)
        @core = core
      end

      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

      private
      attr_reader :core

      def run(where, what)
        system("cd #{where} && #{what}")
      end
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
vpsb-1.1.8 lib/vpsb/commands/deploy.rb
vpsb-1.1.7 lib/vpsb/commands/deploy.rb
vpsb-1.1.6 lib/vpsb/commands/deploy.rb
vpsb-1.1.5 lib/vpsb/commands/deploy.rb
vpsb-1.1.4 lib/vpsb/commands/deploy.rb
vpsb-1.1.3 lib/vpsb/commands/deploy.rb
vpsb-1.1.2 lib/vpsb/commands/deploy.rb