-
To Access Openshit from command you need to install OpenShift command line interface (CLI). Link https://mirror.openshift.com/pub/openshift-v4/clients/ocp/latest/.
-
Download the openshift-client--.* .
-
Windows user need to add the path of the file to environment variable To Help https://www.architectryan.com/2018/03/17/add-to-the-path-on-windows-10/
-
Check the the version through command promit
oc version -
To login the Openshift account using API end point URL
oc login <API END POINT Url> Username: <enter your user anem> Password: <enter your password> -
Creating a new project
oc new-project <projectname> Ex: oc new-project node-test1or creating a project in web console
-
Deploy the application
oc new-app -- name node-express-hello https://github.com/sada498/OpenShift-Apps.git#test-1 --context-dir node-express- hello
Note: #test-1 is the branch of the GitHub repo to test application
-
Open your web console and check the app deploy In developer topology
-
Expose the application to public
oc expose svc/node-express-hello -
Go the web console check the application public end point
- Go to your GitHub project repo then settings
- Click on webhooks > add webhook
- To get the payload URL, switch to the OpenShift web console in your browser, and then click on Builds in the navigation pane.
- Click the your project build config to bring up the Build Config Overview page.
- Scroll to the bottom of this page and locate the Copy URL with Secret link next to the GitHub type.
- Click on the notepad icon to copy the payload URL.

- When you make changes or commits to github project.OpenShift make a automatic builds for the application.

