Skip to content
This repository has been archived by the owner on Aug 2, 2022. It is now read-only.

Latest commit

 

History

History
31 lines (24 loc) · 702 Bytes

Fast CGI configuration.md

File metadata and controls

31 lines (24 loc) · 702 Bytes

Fast CGI configuration of mapping

Use Fast CGI for long running processes of mapping (e.g. to allow caching)

Apache Configuration

Enable mod_proxy_fcgi:

sudo a2enmod proxy_fcgi

Edit Apache conf for a path that connects via FCGI to a given port

ProxyPass "/mapping" "fcgi://localhost:1337/"

Process spawning

Install spawn-fcgi to spawn process(es) of mapping that Apache connect to

sudo apt-get install spawn-fcgi

Spawn a single process of mapping

sudo -u www-data FCGI_WEB_SERVER_ADDRS=127.0.0.1 spawn-fcgi -p 1337 mapping_cgi

Spawn multiple processes of mapping

sudo -u www-data FCGI_WEB_SERVER_ADDRS=127.0.0.1 spawn-fcgi -p 1337 -F 2 mapping_cgi