From b538622441f464f3a163d2fbecee47a29365cab3 Mon Sep 17 00:00:00 2001
From: Benjamin Jee
Date: Thu, 30 Jan 2025 11:07:52 -0800
Subject: [PATCH] Add small feedback
---
apis/v1alpha1/nginxproxy_types.go | 4 ++--
config/crd/bases/gateway.nginx.org_nginxproxies.yaml | 8 ++++----
deploy/crds.yaml | 8 ++++----
.../mode/static/state/dataplane/configuration_test.go | 2 +-
site/content/reference/api.md | 4 ++--
5 files changed, 13 insertions(+), 13 deletions(-)
diff --git a/apis/v1alpha1/nginxproxy_types.go b/apis/v1alpha1/nginxproxy_types.go
index dd558a06d4..ed4ea9ed3d 100644
--- a/apis/v1alpha1/nginxproxy_types.go
+++ b/apis/v1alpha1/nginxproxy_types.go
@@ -193,7 +193,7 @@ const (
IPv6 IPFamilyType = "ipv6"
)
-// RewriteClientIPAddress is a struct that specifies address type and value.
+// RewriteClientIPAddress specifies the address type and value for a RewriteClientIP address.
type RewriteClientIPAddress struct {
// Type specifies the type of address.
Type RewriteClientIPAddressType `json:"type"`
@@ -217,7 +217,7 @@ const (
RewriteClientIPHostnameAddressType RewriteClientIPAddressType = "Hostname"
)
-// NginxPlusAllowAddress is a struct that specifies address type and value.
+// NginxPlusAllowAddress specifies the address type and value for an NginxPlus allow address.
type NginxPlusAllowAddress struct {
// Type specifies the type of address.
Type NginxPlusAllowAddressType `json:"type"`
diff --git a/config/crd/bases/gateway.nginx.org_nginxproxies.yaml b/config/crd/bases/gateway.nginx.org_nginxproxies.yaml
index 970446b983..b842c62214 100644
--- a/config/crd/bases/gateway.nginx.org_nginxproxies.yaml
+++ b/config/crd/bases/gateway.nginx.org_nginxproxies.yaml
@@ -90,8 +90,8 @@ spec:
description: AllowedAddresses specifies IPAddresses or CIDR blocks
to the allow list for accessing the NGINX Plus API.
items:
- description: NginxPlusAllowAddress is a struct that specifies
- address type and value.
+ description: NginxPlusAllowAddress specifies the address type
+ and value for an NginxPlus allow address.
properties:
type:
description: Type specifies the type of address.
@@ -147,8 +147,8 @@ spec:
Sets NGINX directive set_real_ip_from: https://nginx.org/en/docs/http/ngx_http_realip_module.html#set_real_ip_from
This field is required if mode is set.
items:
- description: RewriteClientIPAddress is a struct that specifies
- address type and value.
+ description: RewriteClientIPAddress specifies the address type
+ and value for a RewriteClientIP address.
properties:
type:
description: Type specifies the type of address.
diff --git a/deploy/crds.yaml b/deploy/crds.yaml
index 05c10b89bd..f0547580f1 100644
--- a/deploy/crds.yaml
+++ b/deploy/crds.yaml
@@ -675,8 +675,8 @@ spec:
description: AllowedAddresses specifies IPAddresses or CIDR blocks
to the allow list for accessing the NGINX Plus API.
items:
- description: NginxPlusAllowAddress is a struct that specifies
- address type and value.
+ description: NginxPlusAllowAddress specifies the address type
+ and value for an NginxPlus allow address.
properties:
type:
description: Type specifies the type of address.
@@ -732,8 +732,8 @@ spec:
Sets NGINX directive set_real_ip_from: https://nginx.org/en/docs/http/ngx_http_realip_module.html#set_real_ip_from
This field is required if mode is set.
items:
- description: RewriteClientIPAddress is a struct that specifies
- address type and value.
+ description: RewriteClientIPAddress specifies the address type
+ and value for a RewriteClientIP address.
properties:
type:
description: Type specifies the type of address.
diff --git a/internal/mode/static/state/dataplane/configuration_test.go b/internal/mode/static/state/dataplane/configuration_test.go
index f30397ec8d..0117afecdd 100644
--- a/internal/mode/static/state/dataplane/configuration_test.go
+++ b/internal/mode/static/state/dataplane/configuration_test.go
@@ -4538,7 +4538,7 @@ func TestBuildNginxPlus(t *testing.T) {
expNginxPlus: defaultNginxPlus,
},
{
- msg: "NginxProxy does not specify Nginx Plus settings",
+ msg: "NginxPlus default values are used when NginxProxy doesn't specify NginxPlus settings",
g: &graph.Graph{
NginxProxy: &graph.NginxProxy{
Valid: true,
diff --git a/site/content/reference/api.md b/site/content/reference/api.md
index 0e807788cc..0f829e7ac7 100644
--- a/site/content/reference/api.md
+++ b/site/content/reference/api.md
@@ -1382,7 +1382,7 @@ crit, alert, and emerg messages to be logged. NginxPlus)
-
NginxPlusAllowAddress is a struct that specifies address type and value.
+NginxPlusAllowAddress specifies the address type and value for an NginxPlus allow address.
@@ -1683,7 +1683,7 @@ This field is required if mode is set.
RewriteClientIP)
-
RewriteClientIPAddress is a struct that specifies address type and value.
+RewriteClientIPAddress specifies the address type and value for a RewriteClientIP address.