Today I want to share some hints on ultra-fast bootstrapping developers to use Openshift. Given that adoption in your organisation depends on developers daring and wanting to use Kubernetes/Openshift I believe showing a clear and easy migration path is the way to go.
Teach the Basics by Failing!Actually why not treating Openshift as a user-friendly self-service? Naively approach it and try stuff.
So hold a workshop. Ask people to:
- Not use the CLI for now!!! Don't even think about it. Automation comes later!
- Login and create a project. That usually works well.
- Decide on Docker Image / Source to Image. In the second dialog of the project creation you get presented with those three tabs
Let them choose their poison.
Let the image pull fail because they don't find docker images and don't know that they cannot just fetch stuff from docker.com. Explain why this is the case. Show them where to find your preferred base and runtime images in you internal registry which of course is already configured, ready to be used. Show them the base image you suggest.
Let the template creation fail using an already prepared template. Show were to look up the build error and explain where to find the infamously hidden secrets option everyone needs.
- Once the first build fails: explain the logic of applications in Openshift and that they did not only create a project, but also an application. Show the difference of locating builds and deployments. Show how to access logs of both and how to find 'Edit' hidden in the 'Actions' menu.
- When the build fails du to SSH connection refused: Explain that (even when using a source secret you already prepared) you need to put the public key in your favourite SCM either globally, per project or per repo for the code pull to work.
- When people check the pod first and see it isn't running: Explain again and again the holy trinity of checking stuff:
- First check the build
- Then check the deployment
- Only then check if pods do come up
- Finally the pod is green! People will access the deployed application and ask you how? Now is the time to have a short excurse on service and routing. Maybe show an already configured defautl. If some service isn't accessible:
- Show how to get the pods TCP endpoint
- Show how to attach to a container via the GUI / CLI
Have Docs and Examples ReadyMost important of course is preparation. Do prepare
- Walkthrough screenshots
- At least one runtime template
- At least one base image on your own registry
- At least one S2I ready source repository with a hello-world app
- Global project settings with
- a default SSH key for source pulling
- access configured for your own docker registry
- Maybe make an example project visible for all newbies
Things to avoid...This is of course quite opinionated, but think about it:
- Talk everyone out of setting up Minishift. You just do not want to support this.
- Talk everyone out of getting Compose, Swarm, ... to live along side Openshift. You just do not want to support this. And save everyone the time to spend on having both in their development toolchain.