The recently added (#1084) --oidc-use-access-token argument appears not to be taken into account when determining if the cached token should be used. Therefore when kubectl oidc-login get-token is called with --oidc-use-access-token shortly after it is called without (or vice versa) the same token is returned.
Removing the --token-cache-dir between invocations results in a new token being fetched
To reproduce
diff here exits without finding any differences (status code 0)
Describe the issue
The recently added (#1084)
--oidc-use-access-token
argument appears not to be taken into account when determining if the cached token should be used. Therefore whenkubectl oidc-login get-token
is called with--oidc-use-access-token
shortly after it is called without (or vice versa) the same token is returned.Removing the
--token-cache-dir
between invocations results in a new token being fetchedTo reproduce
diff
here exits without finding any differences (status code 0)or
Your environment
RHEL 8
1.29.0
1.29.4