Re: nginx serving R scripts via CGI/FastRWeb

2013-02-20 Thread Francis Daly
On Wed, Feb 20, 2013 at 08:28:27PM +, Stefan Parvu wrote: > location ~ ^/cgi-bin/R/ { That will match anything starting with /cgi-bin/R/, which is (most of) what you want. These requests will... > fastcgi_pass > unix:/opt/sdr/report/ws/fastcgi_temp/nginx-fcgi.sock; be

Re: nginx serving R scripts via CGI/FastRWeb

2013-02-20 Thread Stefan Parvu
> > "~" means "regex". > "^" means "start of string". > "$" means "end of string". > This location will only match requests that are > /cgi-bin/R > or > > /cgi-bin/R?something > and not > > /cgi-bin/R/something > yep. silly me, I do have a location for all /cgi-bin/R/ calls, like:

Re: nginx serving R scripts via CGI/FastRWeb

2013-02-20 Thread Francis Daly
On Wed, Feb 20, 2013 at 10:00:04AM +, Stefan Parvu wrote: > > Something like (untested by me!) > > location ^~ /cgi-bin/R/ { } > yep correct. I do have now on cgi-bin directory a binary file called: R. > I did change my nginx.conf to have a new location definition for the > R calls, like h

Re: nginx serving R scripts via CGI/FastRWeb

2013-02-20 Thread Stefan Parvu
> > Something like (untested by me!) > location ^~ /cgi-bin/R/ { } > yep correct. I do have now on cgi-bin directory a binary file called: R. I did change my nginx.conf to have a new location definition for the R calls, like here: location ~ ^/cgi-bin/R$ { gzip off;

Re: nginx serving R scripts via CGI/FastRWeb

2013-02-19 Thread Francis Daly
On Tue, Feb 19, 2013 at 12:47:23PM +, Stefan Parvu wrote: Hi there, This location: > location ~ ^/cgi-bin/.*\.cgi$ { will only match some requests that end in ".cgi" (before the ?, if that applies). What you possibly want is a separate location just for your "R" requests. Somethin

Re: nginx serving R scripts via CGI/FastRWeb

2013-02-19 Thread Stefan Parvu
> So Im on option 1: CGI. The client will be this binary which somehow needs to > be > executed for each R script. I placed the Rcgi under cgi.bin directory and > rename it > as R.cgi. > and I forgot to mention for CGI Im using FcgiWrap: http://nginx.localdomain.pl/wiki/FcgiWrap stefan _

Re: nginx serving R scripts via CGI/FastRWeb

2013-02-19 Thread Stefan Parvu
On 11:22 Tue 19 Feb , Harold Sinclair wrote: > Sounds like you ought to try writing a wrapper script ending in .cgi in the > cgi dir that grabs the query string and hands the job off to the R > executable. Not sure if R is required in the cgi-bin directory. You might > have to enable symlinking

Re: nginx serving R scripts via CGI/FastRWeb

2013-02-19 Thread Harold Sinclair
Sounds like you ought to try writing a wrapper script ending in .cgi in the cgi dir that grabs the query string and hands the job off to the R executable. Not sure if R is required in the cgi-bin directory. You might have to enable symlinking out for it to work. On Tue, Feb 19, 2013 at 9:49 AM, S

Re: nginx serving R scripts via CGI/FastRWeb

2013-02-19 Thread Stefan Parvu
On 08:50 Tue 19 Feb , Harold Sinclair wrote: > Does the R cgi script filename end in .cgi ? That's what you specify, it > appears. No, it does not end with cgi since the R scripts will not be called directly by nginx. As I understood I should call the R scripts like: http://localhost/cgi-bin

Re: nginx serving R scripts via CGI/FastRWeb

2013-02-19 Thread Harold Sinclair
Does the R cgi script filename end in .cgi ? That's what you specify, it appears. On Tue, Feb 19, 2013 at 7:47 AM, Stefan Parvu wrote: > Hi, > > Anyone here testing, experimenting with R and nginx ? > Im trying to setup nginx to serve R scripts via > CGI using Rserve, FastRWeb modules as descri

nginx serving R scripts via CGI/FastRWeb

2013-02-19 Thread Stefan Parvu
Hi, Anyone here testing, experimenting with R and nginx ? Im trying to setup nginx to serve R scripts via CGI using Rserve, FastRWeb modules as described here: http://jayemerson.blogspot.fi/2011/10/setting-up-fastrwebrserve-on-ubuntu.html My nginx is configured like: location ~ ^/cgi-b