Method: Boxing::Context#command

Defined in:
lib/boxing/context.rb

#commandArray<String>

Return command options

Returns:

  • (Array<String>)

Since:

  • 0.9.0



147
148
149
150
151
152
153
154
155
# File 'lib/boxing/context.rb', line 147

def command
  return config.command.map(&:to_s) if config.command
  return ['config/environment.Lamby.cmd'] if has?('lamby')
  return ['config/environment.Aws::Rails::SqsActiveJob.lambda_job_handler'] if has?('aws-sdk-rails')
  return ['server'] if has?('openbox')
  return ['server', '-b', '0.0.0.0'] if has?('rails')

  ['rackup', '-o', '0.0.0.0']
end