Nrejve

json3

Jan 5th, 2021
483
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. {
  2.  cat > worker0.mylabserver.com-csr.json << EOF
  3.  {
  4.    "CN": "system:node:worker0.mylabserver.com",
  5.    "key": {
  6.      "algo": "rsa",
  7.      "size": 2048
  8.    },
  9.    "names": [
  10.      {
  11.        "C": "US",
  12.        "L": "Portland",
  13.        "O": "system:nodes",
  14.        "OU": "Kubernetes The Hard Way",
  15.        "ST": "Oregon"
  16.      }
  17.    ]
  18.  }
  19.  EOF
  20.  
  21.  cfssl gencert \
  22.    -ca=ca.pem \
  23.    -ca-key=ca-key.pem \
  24.    -config=ca-config.json \
  25.    -hostname=172.34.1.0,worker0.mylabserver.com \
  26.    -profile=kubernetes \
  27.    worker0.mylabserver.com-csr.json | cfssljson -bare worker0.mylabserver.com
  28.  
  29.  cat > worker1.mylabserver.com-csr.json << EOF
  30.  {
  31.    "CN": "system:node:worker1.mylabserver.com",
  32.    "key": {
  33.      "algo": "rsa",
  34.      "size": 2048
  35.    },
  36.    "names": [
  37.      {
  38.        "C": "US",
  39.        "L": "Portland",
  40.        "O": "system:nodes",
  41.        "OU": "Kubernetes The Hard Way",
  42.        "ST": "Oregon"
  43.      }
  44.    ]
  45.  }
  46.  EOF
  47.  
  48.  cfssl gencert \
  49.    -ca=ca.pem \
  50.    -ca-key=ca-key.pem \
  51.    -config=ca-config.json \
  52.    -hostname=172.34.1.1,worker1.mylabserver.com \
  53.    -profile=kubernetes \
  54.    worker1.mylabserver.com-csr.json | cfssljson -bare worker1.mylabserver.com
  55.  
  56.  }
RAW Paste Data

Adblocker detected! Please consider disabling it...

We've detected AdBlock Plus or some other adblocking software preventing Pastebin.com from fully loading.

We don't have any obnoxious sound, or popup ads, we actively block these annoying types of ads!

Please add Pastebin.com to your ad blocker whitelist or disable your adblocking software.

×