"Unable to connect to the server: x509: certificate signed by unknown authority"의 두 판 사이의 차이

6번째 줄: 6번째 줄:
Unable to connect to the server: x509: certificate signed by unknown authority
Unable to connect to the server: x509: certificate signed by unknown authority
</syntaxhighlight>
</syntaxhighlight>
==방법 1==
<syntaxhighlight lang='console'>
root@wsl:~# kubectl get no --insecure-skip-tls-verify
NAME              STATUS  ROLES    AGE  VERSION
cluster1-node01  Ready    <none>  19d  v1.21.14
cluster1-node02  Ready    <none>  19d  v1.21.14
cluster1-node03  Ready    <none>  13d  v1.21.14
</syntaxhighlight>
==방법 2 ★==
<syntaxhighlight lang='console'>
<syntaxhighlight lang='console'>
root@wsl:~# cat /etc/ssl/certs/company.pem | base64 -w0
root@wsl:~# cat /etc/ssl/certs/company.pem | base64 -w0

2022년 9월 29일 (목) 17:05 판

1 개요

Unable to connect to the server: x509: certificate signed by unknown authority
root@wsl:~# kubectl get no
Unable to connect to the server: x509: certificate signed by unknown authority

2 방법 1

root@wsl:~# kubectl get no --insecure-skip-tls-verify
NAME              STATUS   ROLES    AGE   VERSION
cluster1-node01   Ready    <none>   19d   v1.21.14
cluster1-node02   Ready    <none>   19d   v1.21.14
cluster1-node03   Ready    <none>   13d   v1.21.14

3 방법 2 ★

root@wsl:~# cat /etc/ssl/certs/company.pem | base64 -w0
LS0tLS1CRUdJTiBDRVJUSUZJQ0FURS0tLS0tC...VORCBDRVJUSUZJQ0FURS0tLS0tCg==
root@wsl:~# vi ~/.kube/config
apiVersion: v1
clusters:
- cluster:
    certificate-authority-data: LS0tLS1CRUdJTiBDRVJUSUZJQ0FURS0tLS0tC...VORCBDRVJUSUZJQ0FURS0tLS0tCg== # 교체
    server: https://135.79.246.80
  name: cluster1
...
root@wsl:~# kubectl get no
NAME              STATUS   ROLES    AGE   VERSION
cluster1-node01   Ready    <none>   19d   v1.21.14
cluster1-node02   Ready    <none>   19d   v1.21.14
cluster1-node03   Ready    <none>   13d   v1.21.14

4 참고

문서 댓글 ({{ doc_comments.length }})
{{ comment.name }} {{ comment.created | snstime }}