Last active
December 20, 2015 02:09
-
-
Save charger/6053943 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require File.expand_path(File.join(File.dirname(__FILE__),'..', 'config', 'environment')) | |
require 'evma_httpserver' | |
class HttpServer < EventMachine::Connection | |
include EventMachine::HttpServer | |
def process_http_request | |
@content = Rack::Utils.parse_query(@http_post_content) | |
#or СGI.parse | |
end | |
end | |
EventMachine.run { | |
EventMachine.start_server('0.0.0.0', 3001, HttpServer) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment