Skip to content

Commit b2150a2

Browse files
authored
Merge branch 'main' into nap-release-5.6
2 parents 863efb1 + f99be74 commit b2150a2

File tree

2 files changed

+29
-18
lines changed

2 files changed

+29
-18
lines changed

content/nginx/admin-guide/web-server/reverse-proxy.md

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,13 @@ Proxying is typically used to distribute the load among several servers, seamles
1717

1818
## Passing a Request to a Proxied Server
1919

20-
When NGINX proxies a request, it sends the request to a specified proxied server, fetches the response, and sends it back to the client. It is possible to proxy requests to an HTTP server (another NGINX server or any other server) or a non-HTTP server (which can run an application developed with a specific framework, such as PHP or Python) using a specified protocol. Supported protocols include [FastCGI](https://nginx.org/en/docs/http/ngx_http_fastcgi_module.html), [uwsgi](https://nginx.org/en/docs/http/ngx_http_uwsgi_module.html), [SCGI](https://nginx.org/en/docs/http/ngx_http_scgi_module.html), and [memcached](https://nginx.org/en/docs/http/ngx_http_memcached_module.html).
20+
When NGINX proxies a request, it:
21+
22+
1. Sends the request to a specified proxy server
23+
1. Fetches the response
24+
1. Sends the response back to the client.
25+
26+
It is possible to proxy requests to an HTTP server (another NGINX server or any other server) or a non-HTTP server (which can run an application developed with a specific framework, such as PHP or Python) using a specified protocol. Supported protocols include [FastCGI](https://nginx.org/en/docs/http/ngx_http_fastcgi_module.html), [uwsgi](https://nginx.org/en/docs/http/ngx_http_uwsgi_module.html), [SCGI](https://nginx.org/en/docs/http/ngx_http_scgi_module.html), and [memcached](https://nginx.org/en/docs/http/ngx_http_memcached_module.html).
2127

2228
To pass a request to an HTTP proxied server, the [proxy_pass](https://nginx.org/en/docs/http/ngx_http_proxy_module.html#proxy_pass) directive is specified inside a [location](https://nginx.org/en/docs/http/ngx_http_core_module.html#location). For example:
2329

@@ -35,7 +41,9 @@ location ~ \.php {
3541
}
3642
```
3743

38-
Note that in the first example above, the address of the proxied server is followed by a URI, `/link/`. If the URI is specified along with the address, it replaces the part of the request URI that matches the location parameter. For example, here the request with the `/some/path/page.html` URI will be proxied to `http://www.example.com/link/page.html`. If the address is specified without a URI, or it is not possible to determine the part of URI to be replaced, the full request URI is passed (possibly, modified).
44+
Note that in the first example above, the address of the proxied server is followed by a URI, `/link/`. If the URI is specified along with the address, it replaces the part of the request URI that matches the location parameter.
45+
46+
For example, the request with the `/some/path/page.html` URI will be proxied to `http://www.example.com/link/page.html`. However, if the address is specified without a URI, or it is not possible to determine the part of URI to be replaced, the full request URI is passed (possibly, modified).
3947

4048
To pass a request to a non-HTTP proxied server, the appropriate `**_pass` directive should be used:
4149

@@ -46,14 +54,14 @@ To pass a request to a non-HTTP proxied server, the appropriate `**_pass` direct
4654

4755
Note that in these cases, the rules for specifying addresses may be different. You may also need to pass additional parameters to the server (see the [reference documentation](https://nginx.org/en/docs/) for more detail).
4856

49-
The [proxy_pass](https://nginx.org/en/docs/http/ngx_http_proxy_module.html#proxy_pass) directive can also point to a [named group](https://nginx.org/en/docs/http/load_balancing.html#algorithms) of servers. In this case, requests are distributed among the servers in the group according to the [specified method](https://www.nginx.com/resources/admin-guide/load-balancer/).
57+
The [proxy_pass](https://nginx.org/en/docs/http/ngx_http_proxy_module.html#proxy_pass) directive can also be used to pass requests to a [named group](https://nginx.org/en/docs/http/load_balancing.html#algorithms) of servers. In this case, requests are distributed among the servers in the group according to the [specified method](https://www.nginx.com/resources/admin-guide/load-balancer/).
5058

5159
<span id="headers"></span>
5260
## Passing Request Headers
5361

54-
By default, NGINX redefines two header fields in proxied requests, “Host” and “Connection”, and eliminates the header fields whose values are empty strings. “Host” is set to the `$proxy_host` variable, and “Connection” is set to `close`.
62+
By default, NGINX modifies two header fields in proxied requests, “Host” and “Connection”, and eliminates the header fields whose values are empty strings. “Host” is set to the value of the `$proxy_host` variable, and “Connection” is set to `close`.
5563

56-
To change these setting, as well as modify other header fields, use the [proxy_set_header](https://nginx.org/en/docs/http/ngx_http_proxy_module.html#proxy_set_header) directive. This directive can be specified in a [location](https://nginx.org/en/docs/http/ngx_http_core_module.html#location) or higher. It can also be specified in a particular [server](https://nginx.org/en/docs/http/ngx_http_core_module.html#server) context or in the [http](https://nginx.org/en/docs/http/ngx_http_core_module.html#http) block. For example:
64+
To change these settings, as well as modify other header fields, use the [proxy_set_header](https://nginx.org/en/docs/http/ngx_http_proxy_module.html#proxy_set_header) directive. This directive can be specified in a [location](https://nginx.org/en/docs/http/ngx_http_core_module.html#location) or higher. It can also be specified in a particular [server](https://nginx.org/en/docs/http/ngx_http_core_module.html#server) context or in the [http](https://nginx.org/en/docs/http/ngx_http_core_module.html#http) block. For example:
5765

5866
```nginx
5967
location /some/path/ {
@@ -81,6 +89,8 @@ By default NGINX buffers responses from proxied servers. A response is stored in
8189

8290
The directive that is responsible for enabling and disabling buffering is [proxy_buffering](https://nginx.org/en/docs/http/ngx_http_proxy_module.html#proxy_buffering). By default it is set to `on` and buffering is enabled.
8391

92+
The [proxy_buffers](https://nginx.org/en/docs/http/ngx_http_proxy_module.html#proxy_buffers) and [proxy_buffer_size](https://nginx.org/en/docs/http/ngx_http_proxy_module.html#proxy_buffer_size) directives control how NGINX stores and buffers data.
93+
8494
The [proxy_buffers](https://nginx.org/en/docs/http/ngx_http_proxy_module.html#proxy_buffers) directive controls the size and the number of buffers allocated for a request. The first part of the response from a proxied server is stored in a separate buffer, the size of which is set with the [proxy_buffer_size](https://nginx.org/en/docs/http/ngx_http_proxy_module.html#proxy_buffer_size) directive. This part usually contains a comparatively small response header and can be made smaller than the buffers for the rest of the response.
8595

8696
In the following example, the default number of buffers is increased and the size of the buffer for the first portion of the response is made smaller than the default.
@@ -113,7 +123,7 @@ A common use of a reverse proxy is to provide load balancing. Learn how to impro
113123

114124
If your proxy server has several network interfaces, sometimes you might need to choose a particular source IP address for connecting to a proxied server or an upstream. This may be useful if a proxied server behind NGINX is configured to accept connections from particular IP networks or IP address ranges.
115125

116-
Specify the [proxy_bind](https://nginx.org/en/docs/http/ngx_http_proxy_module.html#proxy_bind) directive and the IP address of the necessary network interface:
126+
In such cases, you can specify the [proxy_bind](https://nginx.org/en/docs/http/ngx_http_proxy_module.html#proxy_bind) directive and the IP address of the necessary network interface:
117127

118128
```nginx
119129
location /app1/ {

content/nim/deploy/kubernetes/deploy-using-helm.md

Lines changed: 13 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ type:
1313

1414
This guide explains how to deploy F5 NGINX Instance Manager on a Kubernetes or OpenShift cluster using Helm. You’ll learn how to download and use Docker images and customize your deployment.
1515

16-
{{< note >}} Starting in NGINX Instance Manager 2.19, you can deploy NGINX Instance Manager on an OpenShift cluster using Helm. {{< /note >}}
16+
{{< note >}} Starting in NGINX Instance Manager 2.19, you can deploy NGINX Instance Manager on an OpenShift cluster using Helm. {{< /note >}}
1717

1818
### About Helm
1919

@@ -81,9 +81,9 @@ Create a Docker registry secret on the cluster, using the JWT token as the usern
8181
-n nms
8282
```
8383

84-
{{< warning >}}
84+
{{< warning >}}
8585

86-
You might see a warning about `--password` being insecure.
86+
You might see a warning about `--password` being insecure.
8787

8888
This can be ignored (since no password is used), but if others have access to this system, delete the JWT token and clear your shell history after deployment.
8989

@@ -174,7 +174,7 @@ The `values.yaml` file customizes the Helm chart installation without modifying
174174

175175
---
176176

177-
## Enabling OpenShift
177+
## Enabling OpenShift
178178

179179
If deploying on OpenShift, include this setting in the `values.yaml` file:
180180

@@ -187,9 +187,9 @@ openshift:
187187

188188
### How OpenShift handles security constraints
189189

190-
When `openshift.enabled: true` is set in the `values.yaml` file, the NGINX Instance Manager deployment automatically creates a **custom [Security Context Constraints](https://docs.redhat.com/en/documentation/openshift_container_platform/4.13/html/authentication_and_authorization/managing-pod-security-policies) (SCCs)** and links it to the Service Account used by all pods.
190+
When `openshift.enabled: true` is set in the `values.yaml` file, the NGINX Instance Manager deployment automatically creates a **custom [Security Context Constraints](https://docs.redhat.com/en/documentation/openshift_container_platform/4.13/html/authentication_and_authorization/managing-pod-security-policies) (SCCs)** and links it to the Service Account used by all pods.
191191

192-
By default, OpenShift enforces strict security policies that require containers to run as **non-root** users. The NGINX Instance Manager deployment needs specific user IDs (UIDs) for certain services, such as **1000** for `nms` and **101** for `nginx` and `clickhouse`. Since the default SCCs do not allow these UIDs, a **custom SCC** is created. This ensures that the deployment can run with the necessary permissions while maintaining OpenShift’s security standards. The custom SCC allows these UIDs by setting the `runAsUser` field, which controls which users can run containers.
192+
By default, OpenShift enforces strict security policies that require containers to run as **non-root** users. The NGINX Instance Manager deployment needs specific user IDs (UIDs) for certain services, such as **1000** for `nms` and **101** for `nginx` and `clickhouse`. Since the default SCCs do not allow these UIDs, a **custom SCC** is created. This ensures that the deployment can run with the necessary permissions while maintaining OpenShift’s security standards. The custom SCC allows these UIDs by setting the `runAsUser` field, which controls which users can run containers.
193193

194194
{{< note >}} If you’re encountering errors with the custom SCC, you may not have permissions to access the Security Context Constraints resource. Please contact a Cluster Administrator to request access, either through a cluster role binding or by adjusting your user role. {{< /note >}}
195195

@@ -271,7 +271,7 @@ To upgrade:
271271

272272
- Replace `<path-to-your-values.yaml>` with the path to the `values.yaml` file you created]({{< relref "/nim/deploy/kubernetes/deploy-using-helm.md#configure-chart" >}}).
273273
- Replace `YourPassword123#` with a secure password that includes uppercase and lowercase letters, numbers, and special characters.
274-
274+
275275
{{<call-out "important" "Save the password!" "" >}} Save this password for future use. Only the encrypted password is stored in Kubernetes, and you can’t recover or reset it later. {{</call-out>}}
276276
- (Optional) Replace <nms-chart-version> with the desired version number. If you don’t specify a version, the latest version will be installed.
277277

@@ -324,9 +324,10 @@ By default, the following network policies will be created in the release namesp
324324
To disable network policies, update the `values.yaml` file:
325325

326326
```yaml
327-
networkPolicies:
328-
# Set this to true to enable network policies for NGINX Instance Manager.
329-
enabled: false
327+
nms-hybrid:
328+
networkPolicies:
329+
# Set this to true to enable network policies for NGINX Instance Manager.
330+
enabled: false
330331
```
331332

332333
---
@@ -371,7 +372,7 @@ The `values.yaml` file customizes the Helm chart installation without modifying
371372
utility:
372373
image:
373374
repository: private-registry.nginx.com/nms/utility
374-
tag: <version>
375+
tag: <version>
375376
```
376377

377378
2. Save and close the `values.yaml` file.
@@ -425,7 +426,7 @@ To upgrade:
425426

426427
- Replace `<path-to-your-values.yaml>` with the path to the `values.yaml` file you created]({{< relref "/nim/deploy/kubernetes/deploy-using-helm.md#configure-chart" >}}).
427428
- Replace `YourPassword123#` with a secure password that includes uppercase and lowercase letters, numbers, and special characters.
428-
429+
429430
{{<call-out "important" "Save the password!" "" >}} Save this password for future use. Only the encrypted password is stored in Kubernetes, and you can’t recover or reset it later. {{</call-out>}}
430431

431432
---

0 commit comments

Comments
 (0)