在使用 EKSCTL 创建 eks 集群时,它会抛出类似的错误error decoding SSH public key
pem文件的权限是400
我正在执行的命令
eksctl create cluster --name=thirdekscluster --ssh-access --ssh-public-key=mysshkey.pem --nodegroup-name=standard-workers --node-type=t3.medium --nodes=3 --nodes-min=1 --nodes-max=4 --node-ami=auto
错误:
[ℹ] using region ap-south-1
[ℹ] setting availability zones to [ap-south-1a ap-south-1c ap-south-1b]
[ℹ] subnets for ap-south-1a - public:xxxxx/19 private:xxxx/19
[ℹ] subnets for ap-south-1c - public:xxxxx/19 private:xxxx/19
[ℹ] subnets for ap-south-1b - public:xxxxx/19 private:xxxx/19
[ℹ] nodegroup "standard-workers" will use "ami-01b6a163133c31994" [AmazonLinux2/1.12]
[✖] computing fingerprint for key "mysshkey.pem":
error decoding SSH public key:
"-----BEGIN RSA PRIVATE KEY
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
-----END RSA PRIVATE KEY-----"
err: illegal base64 data at input byte 0