Hello ! I submitted a csr to be approved and issu...
# general
h
Hello ! I submitted a csr to be approved and issued a certificate. However anytime I run the command below, I get an empty certificate because csr is approved and certificate is not issued. The entire code is documented below. Appreciate your help. NB: RKE
Copy code
openssl genrsa -out newuser.key 2048
openssl req -new -key newuser.key -out newuser.csr -subj "/CN=mike/O=Devops"
-----------------------------------------------------------
apiVersion: certificates.k8s.io/v1
kind: CertificateSigningRequest
metadata:
  name: mike
spec:
  groups:
  - system:authenticated
  request: $(cat newuser.csr | base64 | tr -d "\n")
  signerName: kubernetes.io/kube-apiserver-client
  usages:
  - client auth
--------------------------------------------------------------------
kubectl get csr
kubectl certificate approve mike
kubectl get csr mike -o jsonpath='{.status.certificate}' | base64 -d >> newuser.crt