Re: monit rewrite

Yes but the original request AFAIK is for removing monitor from the URI.
Hence the regex capture.

–appa

Igor S. [email protected] a écrit :

On Thu, Sep 27, 2012 at 09:53:25AM +0200, Antnio P. P. Almeida wrote:

Yes but the original request AFAIK is for removing monitor from the URI. Hence
the regex capture.

http://nginx.org/en/docs/http/ngx_http_proxy_module.html#proxy_pass

If proxy_pass is specified with URI, when passing a request to the
server, part of a normalized request URI matching the location is
replaced by a URI specified in the directive:

location /name/ {
    proxy_pass http://127.0.0.1/remote/;
}


Igor S.
http://nginx.com/support.html

On Thu, Sep 27, 2012 at 11:17:49AM +0100, Mark A. wrote:

    proxy_pass http://127.0.0.1/remote/;
}
  1. Does what is documented about proxy_pass:
    http://nginx.org/en/docs/http/ngx_http_proxy_module.html#proxy_pass
    also applies to fastcgi_pass ?
    http://nginx.org/en/docs/http/ngx_http_fastcgi_module.html#fastcgi_pass

No. The main reason is that there is no URI entity per se in FastCGI.
Instead, there are many ways to say FastCGI servers what it should do.
The common case is a setting script filename in SCRIPT_FILENAME.
But actually FastCGI server can be an application that ignores
SCRIPT_FILENAME and uses, for example, REQUEST_URI instead.

}
Yes.


Igor S.
http://nginx.com/support.html

On Thu, 27 Sep 2012 14:29:48 +0400, Igor S. [email protected] wrote:

  1. Does what is documented about proxy_pass:
    also applies to fastcgi_pass ?
    No. The main reason is that there is no URI entity per se in FastCGI.
  1. Would the following be ok?
    Yes.

Thank you very much Igor.

On Thu, 27 Sep 2012 11:55:38 +0400, Igor S. removed_email_address[email protected] wrote:

On Thu, Sep 27, 2012 at 09:53:25AM +0200, António P. P. Almeida wrote:

http://nginx.org/en/docs/http/ngx_http_proxy_module.html#proxy_pass

If proxy_pass is specified with URI, when passing a request to the
server, part of a normalized request URI matching the location is
replaced by a URI specified in the directive:

location /name/ {
    proxy_pass http://127.0.0.1/remote/;
}
  1. Does what is documented about proxy_pass:
    http://nginx.org/en/docs/http/ngx_http_proxy_module.html#proxy_pass
    also applies to fastcgi_pass ?
    http://nginx.org/en/docs/http/ngx_http_fastcgi_module.html#fastcgi_pass

  2. And is it also valid if using an unix socket instead of
    http://127.0.0.1/?
    Would the following be ok?
    location ^~ /owncloud4/ {
    location ~ ^(?.+.php)(?<path_info>.*)$ {
    include fastcgi_params;
    fastcgi_pass unix:/tmp/php-fpm.socket;
    fastcgi_param SCRIPT_FILENAME $document_root$script;
    fastcgi_param SCRIPT_NAME $script;
    fastcgi_param PATH_INFO $path_info;
    }
    }

Thank you,
Mark

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs