Martin Povolny

View on GitHub

OpenShift command-line cheatsheet

Quick orientation in a project

Creating deployments and deployments configs

Basic oc commands for dealing with Deployments and Deployment config

Create, setup, add a SA (e.g. to fix a deployment needing a process running as root)

  1. oc create sa <sa name>
  2. oc adm policy add-scc-to-user anyuid -z <sa name>
  3. oc set sa

Groups etc.

Remove kubeadmin

https://docs.openshift.com/container-platform/4.6/authentication/remove-kubeadmin.html

oc delete secrets kubeadmin -n kube-system

Setup htpasswd auth for a cluster

Quota

Create an edge route with a self-signed certificate

Taints

Remove taint from a node: