<div dir="ltr">Does the R cgi script filename end in .cgi ? That's what you specify, it appears.</div><div class="gmail_extra"><br><br><div class="gmail_quote">On Tue, Feb 19, 2013 at 7:47 AM, Stefan Parvu <span dir="ltr"><<a href="mailto:sparvu@systemdatarecorder.org" target="_blank">sparvu@systemdatarecorder.org</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi,<br>
<br>
Anyone here testing, experimenting with R and nginx ?<br>
Im trying to setup nginx to serve R scripts via<br>
CGI using Rserve, FastRWeb modules as described here:<br>
<a href="http://jayemerson.blogspot.fi/2011/10/setting-up-fastrwebrserve-on-ubuntu.html" target="_blank">http://jayemerson.blogspot.fi/2011/10/setting-up-fastrwebrserve-on-ubuntu.html</a><br>
<br>
<br>
My nginx is configured like:<br>
<br>
        location ~ ^/cgi-bin/.*\.cgi$ {<br>
            gzip off;<br>
            fastcgi_pass    unix:/opt/sdr/report/ws/fastcgi_temp/nginx-fcgi.sock;<br>
            fastcgi_read_timeout    5m;<br>
            fastcgi_index    index.cgi;<br>
            #fastcgi_buffers  8  4k;<br>
            #<br>
            #  You may copy and paste the lines under or use include directive<br>
            #  include  /etc/nginx/nginx-fcgi.conf;<br>
            #  In this example all is in one file<br>
            #<br>
            fastcgi_param    SCRIPT_NAME  $fastcgi_script_name;<br>
            fastcgi_param    QUERY_STRING  $query_string;<br>
            fastcgi_param    REQUEST_METHOD  $request_method;<br>
            fastcgi_param    CONTENT_TYPE  $content_type;<br>
            fastcgi_param    CONTENT_LENGTH  $content_length;<br>
            fastcgi_param    GATEWAY_INTERFACE  CGI/1.1;<br>
            fastcgi_param    SERVER_SOFTWARE  nginx;<br>
            fastcgi_param    SCRIPT_NAME  $fastcgi_script_name;<br>
            fastcgi_param    REQUEST_URI  $request_uri;<br>
            fastcgi_param    DOCUMENT_URI  $document_uri;<br>
            fastcgi_param    DOCUMENT_ROOT  /opt/sdr/report/docroot;<br>
            fastcgi_param    SERVER_PROTOCOL  $server_protocol;<br>
            fastcgi_param    REMOTE_ADDR  $remote_addr;<br>
            fastcgi_param    REMOTE_PORT  $remote_port;<br>
            fastcgi_param    SERVER_ADDR  $server_addr;<br>
            fastcgi_param    SERVER_PORT  $server_port;<br>
            fastcgi_param    SERVER_NAME  $server_name;<br>
        }<br>
<br>
and Im using fcgiwrap from <a href="http://nginx.localdomain.pl/wiki/FcgiWrap" target="_blank">http://nginx.localdomain.pl/wiki/FcgiWrap</a>.<br>
CGI scripts work fine but Im not able to any R scripts probable due<br>
R being not correctly called via nginx.conf ...<br>
<br>
I am trying something like: <a href="http://localhost/cgi-bin/R/foo.png?n=500" target="_blank">http://localhost/cgi-bin/R/foo.png?n=500</a><br>
and R is a binary file under cgi-bin directory which should call<br>
FastRWeb ...<br>
<br>
Any pointers, help ?<br>
<br>
thanks,<br>
Stefan<br>
<br>
_______________________________________________<br>
nginx mailing list<br>
<a href="mailto:nginx@nginx.org">nginx@nginx.org</a><br>
<a href="http://mailman.nginx.org/mailman/listinfo/nginx" target="_blank">http://mailman.nginx.org/mailman/listinfo/nginx</a><br>
</blockquote></div><br></div>