Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update dependency stern/stern to v1.32.0 #125

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from

Conversation

renovate[bot]
Copy link
Contributor

@renovate renovate bot commented Jan 30, 2023

This PR contains the following updates:

Package Update Change
stern/stern minor v1.22.0 -> v1.32.0

Release Notes

stern/stern (stern/stern)

v1.32.0

Compare Source

⚡ Notable Changes

A new template function prettyJSON

You can now use a new template function prettyJSON that parse input and emit it as pretty printed JSON. If it parse fails output string as is.

v1.31.0

Compare Source

Changes

  • Fix --verbosity flag to show missing logs (#​317) c2b4410 (Takashi Kusumi)
  • Update dependencies for Kubernetes 1.31 (#​315) a4fdcc9 (Takashi Kusumi)

v1.30.0

Compare Source

⚡ Notable Changes

Add support for configuring colors for pods and containers

You can now configure highlight colors for pods and containers in the config file using a comma-separated list of SGR (Select Graphic Rendition) sequences. See the "Customize highlight colors" section for details.

Example configuration:

v1.29.0

Compare Source

⚡ Notable Changes

A new --stdin flag for parsing logs from stdin

A new --stdin flag has been added, allowing parsing logs from stdin. This flag is helpful when applying the same template to local logs.

stern --stdin --template \
  '{{with $msg := .Message | tryParseJSON}}{{toTimestamp $msg.ts "01-02 15:04:05" "Asia/Tokyo"}} {{$msg.msg}}{{"\n"}}{{end}}' \
  <etcd.log

Additionally, this feature helps test your template with arbitrary logs.

stern --stdin --template \
  '{{with $msg := .Message | tryParseJSON}}{{levelColor $msg.level}} {{$msg.msg}}{{"\n"}}{{end}}' <<EOF
{"level":"info","msg":"info message"}
{"level":"error","msg":"error message"}
EOF
Add support for UNIX time with nanoseconds to template functions

The following template functions now support UNIX time seconds with nanoseconds (e.g., 1136171056.02).

  • toRFC3339Nano
  • toTUC
  • toTimestamp

Changes

  • Add support for UNIX time with nanoseconds to template functions (#​300) 0d580ff (Takashi Kusumi)
  • Clarify that '=' cannot be omitted in --timestamps (#​296) ac36420 (Takashi Kusumi)
  • Added example to README (#​295) c1649ca (Thomas Güttler)
  • Update dependencies for Kubernetes 1.30 (#​293) d82cc9f (Kazuki Suda)
  • Add --stdin for stdin log parsing (#​292) 53fc746 (Jimmie Högklint)

v1.28.0

Compare Source

⚡ Notable Changes

Highlight matched strings in the log lines with the highlight option

Some part of a log line can be highlighted while still displaying all other logs lines.

--highlight flag now highlight matched strings in the log lines.

stern --highlight "\[error\]" .

v1.27.0

Compare Source

⚡ Notable Changes

Add new template function: toTimestamp

The toTimestamp function takes in an object, a layout, and optionally a timezone. This allows for more custom time parsing, for instance, if a user doesn't care about seeing the date of the log and only the time (in their own timezone) they can use a template such as:

--template '{{ with $msg := .Message | tryParseJSON }}[{{ toTimestamp $msg.time "15:04:05" "Local" }}] {{ $msg.msg }}{{ end }}{{ "\n" }}'
Add generic kubectl options

stern now has the generic options that kubectl has, and a new --show-hidden-options option.

$ stern --show-hidden-options
The following options can also be used in stern:
      --as string                      Username to impersonate for the operation. User could be a regular user or a service account in a namespace.
      --as-group stringArray           Group to impersonate for the operation, this flag can be repeated to specify multiple groups.
      --as-uid string                  UID to impersonate for the operation.
      --cache-dir string               Default cache directory (default "/home/ksuda/.kube/cache")
      --certificate-authority string   Path to a cert file for the certificate authority
      --client-certificate string      Path to a client certificate file for TLS
      --client-key string              Path to a client key file for TLS
      --cluster string                 The name of the kubeconfig cluster to use
      --disable-compression            If true, opt-out of response compression for all requests to the server
      --insecure-skip-tls-verify       If true, the server's certificate will not be checked for validity. This will make your HTTPS connections insecure
      --request-timeout string         The length of time to wait before giving up on a single server request. Non-zero values should contain a corresponding time unit (e.g. 1s, 2m, 3h). A value of zero means don't timeout requests. (default "0")
      --server string                  The address and port of the Kubernetes API server
      --tls-server-name string         Server name to use for server certificate validation. If it is not provided, the hostname used to contact the server is used
      --token string                   Bearer token for authentication to the API server
      --user string                    The name of the kubeconfig user to use

The number of kubectl generic options is so large that it makes it difficult to see stern's own list of options, so we usually hide them. Use --show-hidden-options if you want to list.

Changes

v1.26.0

Compare Source

⚡ Notable Changes

Add new template functions

The following template functions have been added in v1.26.0:

  • extractJSONParts: Parse string as JSON and concatenate the given keys
  • tryExtractJSONParts: Attempt to parse string as JSON and concatenate the given keys, returning text on failure

Changes

v1.25.0

Compare Source

⚡ Notable Changes

Add support for the config file

You can now use the config file to change the default values of stern options. The default config file path is ~/.config/stern/config.yaml.

v1.24.0

Compare Source

⚡ Notable Changes

Add a short format for timestamps

--timestamps flag now accepts a format, one of default or short.

  • default: the original format 2006-01-02T15:04:05.000000000Z07:00 (RFC3339Nano with trailing zeros)
  • short: the new format 01-02 15:04:05 (time.DateTime without year).

If --timestamps is specified but without value, default is used to maintain backward compatibility.

$ stern --timestamps=short -n kube-system ds/kindnet --no-follow --tail 1 --only-log-lines
kindnet-hqn2k kindnet-cni 03-12 09:29:53 I0312 00:29:53.620499       1 main.go:250] Node kind-worker3 has CIDR [10.244.1.0/24]
kindnet-5f4ms kindnet-cni 03-12 09:29:53 I0312 00:29:53.374482       1 main.go:250] Node kind-worker3 has CIDR [10.244.1.0/24]
Add --node flag to filter on a specific node

New --node flag allows you to filter pods on a specific node. This flag will be helpful when we debug pods on the specific node.

v1.23.0

Compare Source

New features

Add --no-follow flag to exit when all logs have been shown

New --no-follow flag allows you to exit when all logs have been shown.

stern --no-follow .
Support <resource>/<name> form as a query

Stern now supports a Kubernetes resource query in the form <resource>/<name>. Pod query can still be used.

stern deployment/nginx

The following Kubernetes resources are supported:

  • daemonset
  • deployment
  • job
  • pod
  • replicaset
  • replicationcontroller
  • service
  • statefulset

Shell completion of stern already supports this feature.

Add --verbosity flag to set log level verbosity

New --verbosity flag allows you to set the log level verbosity of Kubernetes client-go. This feature is useful when you want to know how stern interacts with a Kubernetes API server in troubleshooting.

stern --verbosity=6 .
Add --only-log-lines flag to print only log lines

New --only-log-lines flag allows you to print only log lines (and errors if occur). The difference between not specifying the flag and specifying it is as follows:

$ stern . --tail=1 --no-follow
+ nginx-cfbcb7b98-96xsv › nginx
+ nginx-cfbcb7b98-29wn7 › nginx
nginx-cfbcb7b98-96xsv nginx 2023/01/27 13:20:48 [notice] 1#1: start worker process 46
- nginx-cfbcb7b98-96xsv › nginx
nginx-cfbcb7b98-29wn7 nginx 2023/01/27 13:20:45 [notice] 1#1: start worker process 46
- nginx-cfbcb7b98-29wn7 › nginx

$ stern . --tail=1 --no-follow --only-log-lines
nginx-cfbcb7b98-96xsv nginx 2023/01/27 13:20:48 [notice] 1#1: start worker process 46
nginx-cfbcb7b98-29wn7 nginx 2023/01/27 13:20:45 [notice] 1#1: start worker process 46

Changes

  • Allow to specify --exclude-pod/container multiple times (#​218) b04478c (Kazuki Suda)
  • Add --only-log-lines flag that prints only log lines (#​216) 995be39 (Kazuki Suda)
  • Fix typo of --verbosity flag (#​215) 6c6db1d (Takashi Kusumi)
  • Add --verbosity flag to set log level verbosity (#​214) 5327626 (Takashi Kusumi)
  • Add completion for flags with pre-defined choices (#​211) e03646c (Takashi Kusumi)
  • Fix bug where container-state is ignored when no-follow specified (#​210) 1bbee8c (Takashi Kusumi)
  • Add dynamic completion for a resource query (#​209) 2983c8f (Takashi Kusumi)
  • Support <resource>/<name> form as a query (#​208) 7bc45f0 (Takashi Kusumi)
  • Fix indent in update-readme.go (#​207) daf2464 (Takashi Kusumi)
  • Update dependencies and tools (#​205) 1bcb576 (Kazuki Suda)
  • Add --no-follow flag to exit when all logs have been shown (#​204) a5e581d (Takashi Kusumi)
  • Use StringArrayVarP for --include and --exclude flags (#​196) 80a68a9 (partcyborg)
  • Fix the invalid command in README.md (#​193) f6e76ba (Kazuki Suda)

Configuration

📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR was generated by Mend Renovate. View the repository job log.

@renovate renovate bot force-pushed the renovate/stern-stern-1.x branch from b546080 to 5ebb8dd Compare March 12, 2023 07:12
@renovate renovate bot changed the title Update dependency stern/stern to v1.23.0 Update dependency stern/stern to v1.24.0 Mar 12, 2023
@renovate renovate bot force-pushed the renovate/stern-stern-1.x branch from 5ebb8dd to acff0af Compare April 14, 2023 00:00
@renovate renovate bot changed the title Update dependency stern/stern to v1.24.0 Update dependency stern/stern to v1.25.0 Apr 14, 2023
@renovate renovate bot force-pushed the renovate/stern-stern-1.x branch from acff0af to 0b2f342 Compare July 10, 2023 08:26
@renovate renovate bot force-pushed the renovate/stern-stern-1.x branch from 0b2f342 to c389325 Compare July 24, 2023 20:16
@renovate renovate bot force-pushed the renovate/stern-stern-1.x branch from c389325 to 19c013a Compare August 9, 2023 13:36
@renovate renovate bot changed the title Update dependency stern/stern to v1.25.0 Update dependency stern/stern to v1.26.0 Aug 21, 2023
@renovate renovate bot force-pushed the renovate/stern-stern-1.x branch from 19c013a to 9f0c26f Compare August 21, 2023 05:16
@renovate renovate bot force-pushed the renovate/stern-stern-1.x branch from 9f0c26f to c4ab2c6 Compare September 19, 2023 13:23
@renovate renovate bot changed the title Update dependency stern/stern to v1.26.0 Update dependency stern/stern to v1.27.0 Nov 15, 2023
@renovate renovate bot force-pushed the renovate/stern-stern-1.x branch from c4ab2c6 to 3f264dc Compare November 15, 2023 03:59
@renovate renovate bot force-pushed the renovate/stern-stern-1.x branch from 3f264dc to 2669c14 Compare January 9, 2024 00:56
@renovate renovate bot changed the title Update dependency stern/stern to v1.27.0 Update dependency stern/stern to v1.28.0 Jan 9, 2024
@renovate renovate bot force-pushed the renovate/stern-stern-1.x branch from 2669c14 to 6c42d5c Compare March 2, 2024 10:04
@renovate renovate bot changed the base branch from master to develop March 2, 2024 10:04
@renovate renovate bot changed the title Update dependency stern/stern to v1.28.0 Update dependency stern/stern to v1.29.0 May 2, 2024
@renovate renovate bot force-pushed the renovate/stern-stern-1.x branch from 6c42d5c to ac8be9a Compare May 2, 2024 10:41
@renovate renovate bot force-pushed the renovate/stern-stern-1.x branch from ac8be9a to f0cc6f3 Compare May 24, 2024 01:54
@renovate renovate bot changed the title Update dependency stern/stern to v1.29.0 Update dependency stern/stern to v1.30.0 May 24, 2024
@renovate renovate bot force-pushed the renovate/stern-stern-1.x branch 2 times, most recently from f929c05 to c5421c8 Compare June 15, 2024 06:57
@renovate renovate bot force-pushed the renovate/stern-stern-1.x branch from c5421c8 to a589b59 Compare August 28, 2024 06:32
@renovate renovate bot force-pushed the renovate/stern-stern-1.x branch from a589b59 to f1a297f Compare October 7, 2024 10:54
@renovate renovate bot changed the title Update dependency stern/stern to v1.30.0 Update dependency stern/stern to v1.31.0 Oct 7, 2024
@renovate renovate bot force-pushed the renovate/stern-stern-1.x branch from f1a297f to 6fac2c7 Compare January 21, 2025 05:46
@renovate renovate bot changed the title Update dependency stern/stern to v1.31.0 Update dependency stern/stern to v1.32.0 Jan 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

0 participants