binki / autoserve

Deploy a node webapp to FastCGI, Passenger, node http, or other things in the future
Other
1 stars 0 forks source link

Better CGI detection #3

Open fbbdev opened 8 years ago

fbbdev commented 8 years ago

Availability of the SCRIPT_NAME variable is not guaranteed and it could also be available but empty. In fact, presence of any CGI variable in the environment should never be taken for granted, but after reading the spec I think the best bet would be GATEWAY_INTERFACE. A compliant server should set it no matter what.