Sha256: e72aa16d4f4f026a693d14bd48da8bfa8100544b7a7a118ea98d4779b02e992f

Contents?: true

Size: 514 Bytes

Versions: 1

Compression:

Stored size: 514 Bytes

Contents

class WebSystem::RackCommand < Liza::Command

  def call args
    log "args = #{args.inspect}"

    strategy = nil
    host = nil
    port = nil

    if args.any? && !args[0].include?("=")
      strategy = args.shift
    end

    args.each do |arg|
      host = arg.split("=")[1] if arg.start_with? "h="
      port = arg.split("=")[1] if arg.start_with? "p="
    end

    log({strategy:, host:, port:})

    rack_panel.call strategy, host, port
  end

  def rack_panel
    @rack_panel ||= WebBox[:rack]
  end

end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
lizarb-1.0.4 lib/web_system/dev/rack_command.rb