Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add boot_from_file_path_cgi #13

Open
wants to merge 54 commits into
base: master
Choose a base branch
from
Open

add boot_from_file_path_cgi #13

wants to merge 54 commits into from

Conversation

kjunichi
Copy link
Contributor

  • write response in your favorite language which support libffi
var onRequest = function(req) {
  console.log('Result is', resultVal);
  // Parse req and return result.
  return "<html>Hello, trusted,this is node.js.</html>";
}
// start http2 trusterd.
mylib.boot_from_file_path_cgi("examples/test.conf.rb",onRequest);
s.set_map_to_storage_cb {
if s.request.uri == "/test"
  p s.request
  s.set_content_cb {
    s.rputs s.unparsed_uri+"\n"
    if s.body
      s.rputs s.body+"\n"
    end
    s.rputs Libtrusterd::Cgi.cgi_proc(SomethinReqObj)
  }
end

TODO

  • implement like request object

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant