Using templates to deploy a multi-tier application
During this lab, we will deploy Gogs (Git repository management software) with a PostgreSQL backend, using all of the knowledge that we have acquired so far.
The Gogs application template
We are going to use a template from the OpenShift demos that are available at https://raw.githubusercontent.com/OpenShiftDemos/gogs-openshift-docker/master/openshift/gogs-template.yaml:
Let's download this template locally using the following command:
# curl -O https://raw.githubusercontent.com/OpenShiftDemos/gogs-openshift-docker/master/openshift/gogs-template.yaml
According to the preceding output, most parameters have a default value (except for the HOSTNAME
parameter). If you need to list parameters separately, you can use the following command:
# oc process --parameters -f gogs-template.yaml
NAME DESCRIPTION GENERATOR VALUE
APPLICATION_NAME The name for the application. gogs
...
<output omitted>
...
Creating the Gogs application
Now that we have...