Skip to content

Commit

Permalink
- refer nginx#5776
Browse files Browse the repository at this point in the history
- commented deprecated include-year and IncludeYear
  • Loading branch information
harsha-mangena committed Jun 21, 2024
1 parent d073aa6 commit 6c91606
Show file tree
Hide file tree
Showing 6 changed files with 21 additions and 23 deletions.
1 change: 0 additions & 1 deletion charts/nginx-ingress/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -277,7 +277,6 @@ Build the args for the service binary.
- -service-insight-tls-secret={{ .Values.serviceInsight.secret }}
- -enable-custom-resources={{ .Values.controller.enableCustomResources }}
- -enable-snippets={{ .Values.controller.enableSnippets }}
- -include-year={{ .Values.controller.includeYear }}
- -disable-ipv6={{ .Values.controller.disableIPV6 }}
{{- if .Values.controller.enableCustomResources }}
- -enable-tls-passthrough={{ .Values.controller.enableTLSPassthrough }}
Expand Down
20 changes: 10 additions & 10 deletions charts/nginx-ingress/values.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -908,14 +908,14 @@
false
]
},
"includeYear": {
"type": "boolean",
"default": false,
"title": "The includeYear",
"examples": [
false
]
},
// "includeYear": {
// "type": "boolean",
// "default": false,
// "title": "The includeYear",
// "examples": [
// false
// ]
// },
"enableTLSPassthrough": {
"type": "boolean",
"default": false,
Expand Down Expand Up @@ -1728,7 +1728,7 @@
"watchNamespace": "",
"enableCustomResources": true,
"enableOIDC": false,
"includeYear": false,
// "includeYear": false,
"enableTLSPassthrough": false,
"tlsPassthroughPort": 443,
"enableCertManager": false,
Expand Down Expand Up @@ -2262,7 +2262,7 @@
"watchNamespace": "",
"enableCustomResources": true,
"enableOIDC": false,
"includeYear": false,
// "includeYear": false,
"enableTLSPassthrough": false,
"enableCertManager": false,
"enableExternalDNS": false,
Expand Down
2 changes: 1 addition & 1 deletion charts/nginx-ingress/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -344,7 +344,7 @@ controller:
enableOIDC: false

## Include year in log header. This parameter will be removed in release 3.7 and the year will be included by default.
includeYear: false
# includeYear: false

## Enable TLS Passthrough on port 443. Requires controller.enableCustomResources.
enableTLSPassthrough: false
Expand Down
13 changes: 6 additions & 7 deletions cmd/nginx-ingress/flags.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ import (
"net"
"os"
"regexp"
"strconv"
"strings"

"github.com/golang/glog"
Expand Down Expand Up @@ -198,8 +197,8 @@ var (
enableExternalDNS = flag.Bool("enable-external-dns", false,
"Enable external-dns controller for VirtualServer resources. Requires -enable-custom-resources")

includeYearInLogs = flag.Bool("include-year", false,
"Option to include the year in the log header")
// includeYearInLogs = flag.Bool("includeYear", false,
// "Option to include the year in the log header")

disableIPV6 = flag.Bool("disable-ipv6", false,
`Disable IPV6 listeners explicitly for nodes that do not support the IPV6 stack`)
Expand Down Expand Up @@ -305,10 +304,10 @@ func initialChecks() {
glog.Fatalf("Error setting logtostderr to true: %v", err)
}

err = flag.Lookup("include_year").Value.Set(strconv.FormatBool(*includeYearInLogs))
if err != nil {
glog.Fatalf("Error setting include_year flag: %v", err)
}
// err = flag.Lookup("include_year").Value.Set(strconv.FormatBool(*includeYearInLogs))
// if err != nil {
// glog.Fatalf("Error setting include_year flag: %v", err)
// }

if startupCheckFn != nil {
err := startupCheckFn()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,13 +81,13 @@ Default `false`.

---

### -include-year
<!-- ### -include-year
Adds year to log headers.
Adds year to log headers.
Default `false`.
{{< note >}} This flag will be removed in release 3.7 and the year will be included by default. {{< /note >}}
{{< note >}} This flag will be removed in release 3.7 and the year will be included by default. {{< /note >}} -->

---

Expand Down
2 changes: 1 addition & 1 deletion docs/content/releases.md
Original file line number Diff line number Diff line change
Expand Up @@ -744,7 +744,7 @@ We will provide technical support for NGINX Ingress Controller on any Kubernetes
- VirtualServer resource now supports [wildcard hostname](https://kubernetes.io/docs/concepts/services-networking/ingress/#hostname-wildcards).
- NGINX Ingress Controller images including the combined NGINX AppProtect WAF and NGINX AppProtect DoS solutions are now published to our registry. See [Images with NGINX Plus](https://docs.nginx.com/nginx-ingress-controller/technical-specifications/#images-with-nginx-plus) for a detailed list of images in our registry.
- Added support for watching multiple namespaces using the [-watch-namespace](https://docs.nginx.com/nginx-ingress-controller/configuration/global-configuration/command-line-arguments/#-watch-namespace-string) cli argument. This can configured by passing a comma-separated list of namespaces to the `-watch-namespace` CLI argument (e.g. `-watch-namespace=ns-1,ns-2`).
- A new cli argument has been added: [-include-year](https://docs.nginx.com/nginx-ingress-controller/configuration/global-configuration/command-line-arguments/#-include-year). This appends the current year to the log output from the Ingress Controller. Example output: `I20220512 09:20:42.345457`.
<!-- - A new cli argument has been added: [-include-year](https://docs.nginx.com/nginx-ingress-controller/configuration/global-configuration/command-line-arguments/#-include-year). This appends the current year to the log output from the Ingress Controller. Example output: `I20220512 09:20:42.345457`. -->
- Post-startup configuration reloads have been optimized to reduce traffic impacts. When many resources are modified at the same time, changes are combined to reduce the number of data plane reloads.

### <i class="fa-solid fa-rocket"></i> Features
Expand Down

0 comments on commit 6c91606

Please sign in to comment.