Last active
February 11, 2020 04:48
-
-
Save devx/05c4750d4e243181dc239f4cfcddc893 to your computer and use it in GitHub Desktop.
ocp build notes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Create the config and edit necesary fields | |
openshift-install create install-config --dir $HOME/cluster-${GUID} | |
# create the cluster | |
openshift-install create cluster --dir $HOME/cluster-${GUID} | |
#Create a httpassword file | |
#apply identity provider via web ui | |
https://console-openshift-console.example.com/k8s/cluster/config.openshift.io~v1~OAuth/cluster | |
#login and verify all users (you have to login in order for OCP to create a user object. | |
for user in john paul ringo george pete | |
> do | |
> echo "$user" | |
> oc login -u $user -p openshift4 | |
> done | |
# get all users | |
oc get users | |
# give user cluster admin | |
oc adm policy add-cluster-role-to-user cluster-admin <user> | |
#MOve router to infra node | |
oc patch ingresscontroller default -n openshift-ingress-operator --type=merge --patch='{"spec":{"nodePlacement":{"nodeSelector": {"matchLabels":{"node-role.kubernetes.io/infra":""}}}}}' | |
``` | |
nodeSelector: | |
node-role.kubernetes.io/infra: "" | |
``` | |
#Move registry to infra node | |
oc patch configs.imageregistry.operator.openshift.io/cluster -n openshift-image-registry --type=merge --patch '{"spec": {"nodeSelector":{"node-role.kubernetes.io/infra":""}}}' | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment