This is a sample repo that contains the source code for the nginx application that can be deployed as container or on OpenShift, the index page also displays an welcome message for IBM zCX on OpenShift.
- Create your project namespace in the cluster.
- Click the
+Add
tab in the left menu.
- Click the
Git Repository
tab in the main page.
- Copy this repo or your forked repo url in to the
Git Repo URL
input and set theTarget Port
's value to be 8080.
- Click the
Create
button to deploy the sample nginx, you should then be redirected to the deployment typology page. Wait for the cluster to finish build the container image and verify the "green check mark" in theBuilds
section, then wait and verify the pod isRunning
under the Pods section.
- Click the url location under the
Routes
section to view the index page of your sample nginx application.
- Modify the the source code in git repo, here we changed the header text in the
index.html
page.
- Once the change has been commited, go back to OpenShift web console and click the
Start Build
button in the deployment typology page to rebuild the nginx contianer image, onces the new image is built, OpenShift will automatically deploy the new container.
- Open the same url location under the
Routes
section for nginx application or refresh the nginx index page, you should see the header change.