Skip to content

OpenShift Examples

Run OpenShift on your Hetzner Server

https://github.com/RedHat-EMEA-SSA-Team/hetzner-ocp4

Run OCP on your laptop

OpenShift 4

Code Ready Containers

OpenShift 3

1
2
oc cluster up --image=registry.access.redhat.com/openshift3/ose \
  --public-hostname=localhost

Usefull Red Hat Solutions article

Article Note
How can a user update OpenShift 4 console route
Red Hat Operators Supported in Disconnected Mode
Support Policies for Red Hat OpenShift Container Platform Clusters - Deployments Spanning Multiple Sites(Data Centers/Regions)

Usefull commands

Easy install jq on RHEL

1
2
3
curl -O -L https://github.com/stedolan/jq/releases/download/jq-1.6/jq-linux64
chmod +x jq-linux64
sudo mv jq-linux64 /usr/local/bin/jq

jq examples

PVC CSV

1
oc get pvc --all-namespaces -o json | jq -r  ' .items[] |  [.metadata.namespace,.metadata.name,.status.capacity.storage|tostring]|@csv'
1
2
3
oc get secret -n openshift-web-console webconsole-serving-cert -o json | jq -r '.data."tls.crt"' | base64 -d > foo.pem
# Can't use openssl x509, x509 do not support bundles
openssl crl2pkcs7 -nocrl -certfile foo.pem | openssl pkcs7 -print_certs  -noout

Check certificate from master-api

1
echo -n | openssl s_client -connect q.bohne.io:8443 -servername q.bohne.io 2>/dev/null | openssl x509 -noout -subject -issuer

OpenShift certificate overview:

1
find /etc/origin/master/ /etc/origin/node -name "*.crt" -printf '%p - ' -exec openssl x509 -noout -subject -in {} \;

Stargazers over time

Stargazers over time


Last update: September 19, 2020