Sha256: 9bab2bdaeeb93810c35aef7f17a186b0bee43ce58069b768da71de4a2d37b1de

Contents?: true

Size: 916 Bytes

Versions: 23

Compression:

Stored size: 916 Bytes

Contents

# frozen_string_literal: true

require 'avm/eac_rails_base1/runner_with/bundle'
require 'avm/instances/entry_keys'
require 'eac_cli/core_ext'
require 'eac_ruby_utils/console/docopt_runner'
require 'shellwords'

module Avm
  module EacRailsBase1
    class Runner < ::Avm::EacWebappBase0::Runner
      class RailsServer
        DEFAULT_RAILS_ENVIRONMENT = 'development'
        runner_with :help, ::Avm::EacRailsBase1::RunnerWith::Bundle do
          desc 'Run the embbeded Rails web server.'
        end

        def run
          infov 'Environment', rails_environment
          infov 'Bundle args', ::Shellwords.join(bundle_args)
          infov 'Result', bundle_command.system
        end

        protected

        def bundle_args
          ['exec', 'rails', 'server', '--port',
           runner_context.call(:instance).read_entry(::Avm::Instances::EntryKeys::WEB_PORT)]
        end
      end
    end
  end
end

Version data entries

23 entries across 23 versions & 1 rubygems

Version Path
avm-tools-0.97.0 lib/avm/eac_rails_base1/runner/rails_server.rb
avm-tools-0.96.0 lib/avm/eac_rails_base1/runner/rails_server.rb
avm-tools-0.95.0 lib/avm/eac_rails_base1/runner/rails_server.rb
avm-tools-0.94.3 lib/avm/eac_rails_base1/runner/rails_server.rb
avm-tools-0.94.2 lib/avm/eac_rails_base1/runner/rails_server.rb
avm-tools-0.94.1 lib/avm/eac_rails_base1/runner/rails_server.rb
avm-tools-0.94.0 lib/avm/eac_rails_base1/runner/rails_server.rb
avm-tools-0.93.0 lib/avm/eac_rails_base1/runner/rails_server.rb
avm-tools-0.92.0 lib/avm/eac_rails_base1/runner/rails_server.rb
avm-tools-0.91.0 lib/avm/eac_rails_base1/runner/rails_server.rb
avm-tools-0.90.0 lib/avm/eac_rails_base1/runner/rails_server.rb
avm-tools-0.89.0 lib/avm/eac_rails_base1/runner/rails_server.rb
avm-tools-0.88.0 lib/avm/eac_rails_base1/runner/rails_server.rb
avm-tools-0.87.1 lib/avm/eac_rails_base1/runner/rails_server.rb
avm-tools-0.87.0 lib/avm/eac_rails_base1/runner/rails_server.rb
avm-tools-0.86.0 lib/avm/eac_rails_base1/runner/rails_server.rb
avm-tools-0.85.1 lib/avm/eac_rails_base1/runner/rails_server.rb
avm-tools-0.85.0 lib/avm/eac_rails_base1/runner/rails_server.rb
avm-tools-0.84.0 lib/avm/eac_rails_base1/runner/rails_server.rb
avm-tools-0.83.0 lib/avm/eac_rails_base1/runner/rails_server.rb