Sha256: 73961743e74127173480dd2c80d4ad056dee5dd843b4a5369c1b61c62d37d258

Contents?: true

Size: 313 Bytes

Versions: 1

Compression:

Stored size: 313 Bytes

Contents

require 'webrick'

module Florby
  class Server
    def self.run
      new.run
    end

    def run
      server = WEBrick::HTTPServer.new(
        DocumentRoot: File.join(Dir.pwd, '_build'),
        Port: 8081,
      )

      trap(:INT) do
        server.shutdown
      end

      server.start
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
florby-0.1.0 lib/florby/server.rb