It's not. It's generated internally by the apiserver when the --cert-dir option is added to the kube-apiserver args. K3s doesn't enable this by default, but rancher does.
creamy-pencil-82913
10/17/2023, 7:14 AM
If you need to regenerate it, just delete the cert and key and restart k3s
m
microscopic-fountain-47918
10/17/2023, 7:27 AM
So,I should to check the api-server's source code.Right?Beacause I want to generate a certificate with a specified validity period when I installing K3s
c
creamy-pencil-82913
10/17/2023, 4:00 PM
You'd need to generate your own cert, put it in a location accessible to k3s, and then add the correct apiserver args to tell the apiserver to use it.