Methods

Rocket uses Methods as a way to serve different types of content. Currently there is one method:

  • wsgi - Serves a WSGI-compliant application.

WSGI

The wsgi method is implemented by the WSGIWorker class.

The app_info property for the WSGIWorker should be a dictionary containing the following:

  • wsgi_app: an instance of the WSGI application Rocket should serve.

Rocket provides the following environment variables to applications that it runs in addition to WSGI’s standard environment variables:

  • REMOTE_PORT - the port from which the client computer is connecting.
  • REMOTE_ADDR - the IP address of the device directly connected to the server. Note: IP addresses can be spoofed or hidden behind a proxy, NAT device or redirector. This IP address is not guaranteed to reflect the true client’s IP address.

Since Rocket does not currently support HTTP-authentication, REMOTE_USER is never provided.

Table Of Contents

Previous topic

Using Rocket

Next topic

Design

This Page