node-cert-exporter
node-cert-exporter copied to clipboard
Add okd support
сс @amimof
@Asgoret Thanks for contributing. Can you please provide a bit more details. Is there a reason why OKD is different from the existing K8S daemonset manifest? What is the reason for using jsonnet? Is there a chance that the jsonnet implementation is generic and not specific for OpenShift?
@amimof Hi!
- OKD by design have a more secure environment. So you can't just add daemonset with mounting something from the host machine. Also I there is another ways for certificates (e.g.
~/kubernetes/pkidoesn't exist at all) and I add ETCD certificates for monitoring - Jsonnet used just for generating YAML files for the different environment (e.g. image version or namespace)
- jsonnet used with ksonnet so it prepares YAML basically for k8s API. But, as OKD based on k8s we can deploy in OKD too.
UPD: Also I add grafana dashboard (forget is at first (sic!))
@amimof all good?
Ok I understand. However I believe the jsonnet files are somewhat out of scope of this project since it is possible to deploy rendered yaml manifests to OKD. How those files are rendered to begin with is up to the user.
- The files
okd/rendered/node-cert-exporter-daemonset.yaml,okd/rendered/node-cert-exporter-service.yaml,okd/rendered/node-cert-exporter-serviceAccount.yaml, andokd/rendered/node-cert-exporter-serviceMonitor.yamlcan be merge into one file. - The command
oc adm policy add-scc-to-user hostmount-anyuid -n monitoring -z node-cert-exporteressentially creates aClusterRoleBindingwhich can be put as yaml into the manifest. All this makes for a much cleaner and simpler example.
And lastly, please put the okd/ folder under deploy
- Jsonnet is something for development. If someone wants to develop their own version with own limits or tags he will be creating some template file. Not in scope, but good thing I think)
- The long file is not good to practise because it harder for development and check before deploying and hard to store version in git
- SCC is not a CRB. It's security context and is OKD abstraction, not Kubernetes