I'm pretty sure it is intentional that the only variables available are the
ones defined in the template itself.

On Fri, Apr 8, 2016 at 3:29 PM, Dale Bewley <[email protected]> wrote:

> I'm creating a template which has 2 services. One is a python gunicorn and
> one is httpd.
>
> I want the first service reachable at app-project.domain/ and the second
> service to be reachable at app-project.domain/static. That works, but I'm
> having trouble automating it in a template.
>
> Unfortunately if I use default value of ${APPLICATION_DOMAIN} it includes
> the service name and I wind up with a distinct hostname in each route:
> app-static-project.domain and app-py-project.domain
>
>     {
>       "kind": "Route",
>       "apiVersion": "v1",
>       "metadata": {
>         "name": "${NAME}-static"
>       },
>       "spec": {
>         "host": "${APPLICATION_DOMAIN}",
>         "path": "/${STATIC_DIR}",
>         "to": {
>           "kind": "Service",
>           "name": "${NAME}-static"
>         },
>         "tls": {
>           "termination" : "edge"
>         }
>       }
>     },
>     {
>       "kind": "Route",
>       "apiVersion": "v1",
>       "metadata": {
>         "name": "${NAME}-py"
>       },
>       "spec": {
>         "host": "${APPLICATION_DOMAIN}",
>         "to": {
>           "kind": "Service",
>           "name": "${NAME}-py"
>         },
>         "tls": {
>           "termination" : "edge"
>         }
>       }
>     },
>
>
> I could prompt for a hostname, but I would like to auto-generate the
> hostname to include the project by default. What I would like is
> <app>-<project>.<cloud_apps_domain> in both routes.
>
>
> Is is there a list somewhere of the variables available to templates?
>
> _______________________________________________
> users mailing list
> [email protected]
> http://lists.openshift.redhat.com/openshiftmm/listinfo/users
>
_______________________________________________
users mailing list
[email protected]
http://lists.openshift.redhat.com/openshiftmm/listinfo/users

Reply via email to