Sha256: efed95ae445b4a17be9e1694cb2da7876dd2da6abc28740d209aabf6795d08d9
Contents?: true
Size: 382 Bytes
Versions: 7
Compression:
Stored size: 382 Bytes
Contents
#!/usr/bin/env ruby require 'webrick' require 'soap/property' docroot = "." port = 8808 if opt = SOAP::Property.loadproperty("samplehttpd.conf") docroot = opt["docroot"] port = Integer(opt["port"]) end s = WEBrick::HTTPServer.new( :BindAddress => "0.0.0.0", :Port => port, :DocumentRoot => docroot, :CGIPathEnv => ENV['PATH'] ) trap(:INT) do s.shutdown end s.start
Version data entries
7 entries across 7 versions & 2 rubygems