Mercurial > hg > nginx-site
comparison xml/en/docs/http/ngx_http_proxy_module.xml @ 2598:361a28cca097
Rephrased "off" parameter of proxy_cookie_domain/path/redirect.
author | Yaroslav Zhuravlev <yar@nginx.com> |
---|---|
date | Fri, 24 Jul 2020 13:43:21 +0100 |
parents | eeed494bba51 |
children | 5c5a36560f97 |
comparison
equal
deleted
inserted
replaced
2597:c9545c331582 | 2598:361a28cca097 |
---|---|
8 <!DOCTYPE module SYSTEM "../../../../dtd/module.dtd"> | 8 <!DOCTYPE module SYSTEM "../../../../dtd/module.dtd"> |
9 | 9 |
10 <module name="Module ngx_http_proxy_module" | 10 <module name="Module ngx_http_proxy_module" |
11 link="/en/docs/http/ngx_http_proxy_module.html" | 11 link="/en/docs/http/ngx_http_proxy_module.html" |
12 lang="en" | 12 lang="en" |
13 rev="67"> | 13 rev="68"> |
14 | 14 |
15 <section id="summary"> | 15 <section id="summary"> |
16 | 16 |
17 <para> | 17 <para> |
18 The <literal>ngx_http_proxy_module</literal> module allows passing | 18 The <literal>ngx_http_proxy_module</literal> module allows passing |
859 proxy_cookie_domain ~\.(?P<sl_domain>[-0-9a-z]+\.[a-z]+)$ $sl_domain; | 859 proxy_cookie_domain ~\.(?P<sl_domain>[-0-9a-z]+\.[a-z]+)$ $sl_domain; |
860 </example> | 860 </example> |
861 </para> | 861 </para> |
862 | 862 |
863 <para> | 863 <para> |
864 There could be several <literal>proxy_cookie_domain</literal> directives: | 864 Several <literal>proxy_cookie_domain</literal> directives |
865 can be specified on the same level: | |
865 <example> | 866 <example> |
866 proxy_cookie_domain localhost example.org; | 867 proxy_cookie_domain localhost example.org; |
867 proxy_cookie_domain ~\.([a-z]+\.[a-z]+)$ $1; | 868 proxy_cookie_domain ~\.([a-z]+\.[a-z]+)$ $1; |
868 </example> | 869 </example> |
869 </para> | 870 The <literal>off</literal> parameter cancels the effect |
870 | 871 of the <literal>proxy_cookie_domain</literal> directives |
871 <para> | 872 inherited from the previous configuration level. |
872 The <literal>off</literal> parameter cancels the effect of all | |
873 <literal>proxy_cookie_domain</literal> directives on the current level: | |
874 <example> | |
875 proxy_cookie_domain off; | |
876 proxy_cookie_domain localhost example.org; | |
877 proxy_cookie_domain www.example.org example.org; | |
878 </example> | |
879 </para> | 873 </para> |
880 | 874 |
881 </directive> | 875 </directive> |
882 | 876 |
883 | 877 |
925 proxy_cookie_path ~*^/user/([^/]+) /u/$1; | 919 proxy_cookie_path ~*^/user/([^/]+) /u/$1; |
926 </example> | 920 </example> |
927 </para> | 921 </para> |
928 | 922 |
929 <para> | 923 <para> |
930 There could be several <literal>proxy_cookie_path</literal> directives: | 924 Several <literal>proxy_cookie_path</literal> directives |
925 can be specified on the same level: | |
931 <example> | 926 <example> |
932 proxy_cookie_path /one/ /; | 927 proxy_cookie_path /one/ /; |
933 proxy_cookie_path / /two/; | 928 proxy_cookie_path / /two/; |
934 </example> | 929 </example> |
935 </para> | 930 The <literal>off</literal> parameter cancels the effect |
936 | 931 of the <literal>proxy_cookie_path</literal> directives |
937 <para> | 932 inherited from the previous configuration level. |
938 The <literal>off</literal> parameter cancels the effect of all | |
939 <literal>proxy_cookie_path</literal> directives on the current level: | |
940 <example> | |
941 proxy_cookie_path off; | |
942 proxy_cookie_path /two/ /; | |
943 proxy_cookie_path ~*^/user/([^/]+) /u/$1; | |
944 </example> | |
945 </para> | 933 </para> |
946 | 934 |
947 </directive> | 935 </directive> |
948 | 936 |
949 | 937 |
1655 proxy_redirect ~*/user/([^/]+)/(.+)$ http://$1.example.com/$2; | 1643 proxy_redirect ~*/user/([^/]+)/(.+)$ http://$1.example.com/$2; |
1656 </example> | 1644 </example> |
1657 </para> | 1645 </para> |
1658 | 1646 |
1659 <para> | 1647 <para> |
1660 There could be several <literal>proxy_redirect</literal> directives: | 1648 Several <literal>proxy_redirect</literal> directives |
1649 can be specified on the same level: | |
1661 <example> | 1650 <example> |
1662 proxy_redirect default; | 1651 proxy_redirect default; |
1663 proxy_redirect http://localhost:8000/ /; | 1652 proxy_redirect http://localhost:8000/ /; |
1664 proxy_redirect http://www.example.com/ /; | 1653 proxy_redirect http://www.example.com/ /; |
1665 </example> | 1654 </example> |
1666 </para> | 1655 The <literal>off</literal> parameter cancels the effect |
1667 | 1656 of the <literal>proxy_redirect</literal> directives |
1668 <para> | 1657 inherited from the previous configuration level. |
1669 The <literal>off</literal> parameter cancels the effect of all | |
1670 <literal>proxy_redirect</literal> directives on the current level: | |
1671 <example> | |
1672 proxy_redirect off; | |
1673 proxy_redirect default; | |
1674 proxy_redirect http://localhost:8000/ /; | |
1675 proxy_redirect http://www.example.com/ /; | |
1676 </example> | |
1677 </para> | 1658 </para> |
1678 | 1659 |
1679 <para> | 1660 <para> |
1680 Using this directive, it is also possible to add host names to relative | 1661 Using this directive, it is also possible to add host names to relative |
1681 redirects issued by a proxied server: | 1662 redirects issued by a proxied server: |