parameterize name

This commit is contained in:
gabemontero 2016-03-10 16:59:16 -05:00
parent 3375b23fc8
commit 85e79a7a71
2 changed files with 38 additions and 24 deletions

View file

@ -17,7 +17,7 @@
"kind": "Service", "kind": "Service",
"apiVersion": "v1", "apiVersion": "v1",
"metadata": { "metadata": {
"name": "django-psql-example", "name": "${NAME}",
"annotations": { "annotations": {
"description": "Exposes and load balances the application pods" "description": "Exposes and load balances the application pods"
} }
@ -31,7 +31,7 @@
} }
], ],
"selector": { "selector": {
"name": "django-psql-example" "name": "${NAME}"
} }
} }
}, },
@ -39,13 +39,13 @@
"kind": "Route", "kind": "Route",
"apiVersion": "v1", "apiVersion": "v1",
"metadata": { "metadata": {
"name": "django-psql-example" "name": "${NAME}"
}, },
"spec": { "spec": {
"host": "${APPLICATION_DOMAIN}", "host": "${APPLICATION_DOMAIN}",
"to": { "to": {
"kind": "Service", "kind": "Service",
"name": "django-psql-example" "name": "${NAME}"
} }
} }
}, },
@ -53,7 +53,7 @@
"kind": "ImageStream", "kind": "ImageStream",
"apiVersion": "v1", "apiVersion": "v1",
"metadata": { "metadata": {
"name": "django-psql-example", "name": "${NAME}",
"annotations": { "annotations": {
"description": "Keeps track of changes in the application image" "description": "Keeps track of changes in the application image"
} }
@ -63,7 +63,7 @@
"kind": "BuildConfig", "kind": "BuildConfig",
"apiVersion": "v1", "apiVersion": "v1",
"metadata": { "metadata": {
"name": "django-psql-example", "name": "${NAME}",
"annotations": { "annotations": {
"description": "Defines how to build the application" "description": "Defines how to build the application"
} }
@ -90,7 +90,7 @@
"output": { "output": {
"to": { "to": {
"kind": "ImageStreamTag", "kind": "ImageStreamTag",
"name": "django-psql-example:latest" "name": "${NAME}:latest"
} }
}, },
"triggers": [ "triggers": [
@ -116,7 +116,7 @@
"kind": "DeploymentConfig", "kind": "DeploymentConfig",
"apiVersion": "v1", "apiVersion": "v1",
"metadata": { "metadata": {
"name": "django-psql-example", "name": "${NAME}",
"annotations": { "annotations": {
"description": "Defines how to deploy the application server" "description": "Defines how to deploy the application server"
} }
@ -135,7 +135,7 @@
], ],
"from": { "from": {
"kind": "ImageStreamTag", "kind": "ImageStreamTag",
"name": "django-psql-example:latest" "name": "${NAME}:latest"
} }
} }
}, },
@ -145,13 +145,13 @@
], ],
"replicas": 1, "replicas": 1,
"selector": { "selector": {
"name": "django-psql-example" "name": "${NAME}"
}, },
"template": { "template": {
"metadata": { "metadata": {
"name": "django-psql-example", "name": "${NAME}",
"labels": { "labels": {
"name": "django-psql-example" "name": "${NAME}"
} }
}, },
"spec": { "spec": {
@ -337,6 +337,13 @@
} }
], ],
"parameters": [ "parameters": [
{
"name": "NAME",
"displayName": "Name",
"description": "The name assigned to all of the frontend objects defined in this template.",
"required": true,
"value": "django-psql-example"
},
{ {
"name": "MEMORY_LIMIT", "name": "MEMORY_LIMIT",
"displayName": "Memory Limit", "displayName": "Memory Limit",

View file

@ -17,7 +17,7 @@
"kind": "Service", "kind": "Service",
"apiVersion": "v1", "apiVersion": "v1",
"metadata": { "metadata": {
"name": "django-example", "name": "${NAME}",
"annotations": { "annotations": {
"description": "Exposes and load balances the application pods" "description": "Exposes and load balances the application pods"
} }
@ -31,7 +31,7 @@
} }
], ],
"selector": { "selector": {
"name": "django-example" "name": "${NAME}"
} }
} }
}, },
@ -39,13 +39,13 @@
"kind": "Route", "kind": "Route",
"apiVersion": "v1", "apiVersion": "v1",
"metadata": { "metadata": {
"name": "django-example" "name": "${NAME}"
}, },
"spec": { "spec": {
"host": "${APPLICATION_DOMAIN}", "host": "${APPLICATION_DOMAIN}",
"to": { "to": {
"kind": "Service", "kind": "Service",
"name": "django-example" "name": "${NAME}"
} }
} }
}, },
@ -53,7 +53,7 @@
"kind": "ImageStream", "kind": "ImageStream",
"apiVersion": "v1", "apiVersion": "v1",
"metadata": { "metadata": {
"name": "django-example", "name": "${NAME}",
"annotations": { "annotations": {
"description": "Keeps track of changes in the application image" "description": "Keeps track of changes in the application image"
} }
@ -63,7 +63,7 @@
"kind": "BuildConfig", "kind": "BuildConfig",
"apiVersion": "v1", "apiVersion": "v1",
"metadata": { "metadata": {
"name": "django-example", "name": "${NAME}",
"annotations": { "annotations": {
"description": "Defines how to build the application" "description": "Defines how to build the application"
} }
@ -90,7 +90,7 @@
"output": { "output": {
"to": { "to": {
"kind": "ImageStreamTag", "kind": "ImageStreamTag",
"name": "django-example:latest" "name": "${NAME}:latest"
} }
}, },
"triggers": [ "triggers": [
@ -116,7 +116,7 @@
"kind": "DeploymentConfig", "kind": "DeploymentConfig",
"apiVersion": "v1", "apiVersion": "v1",
"metadata": { "metadata": {
"name": "django-example", "name": "${NAME}",
"annotations": { "annotations": {
"description": "Defines how to deploy the application server" "description": "Defines how to deploy the application server"
} }
@ -135,7 +135,7 @@
], ],
"from": { "from": {
"kind": "ImageStreamTag", "kind": "ImageStreamTag",
"name": "django-example:latest" "name": "${NAME}:latest"
} }
} }
}, },
@ -145,13 +145,13 @@
], ],
"replicas": 1, "replicas": 1,
"selector": { "selector": {
"name": "django-example" "name": "${NAME}"
}, },
"template": { "template": {
"metadata": { "metadata": {
"name": "django-example", "name": "${NAME}",
"labels": { "labels": {
"name": "django-example" "name": "${NAME}"
} }
}, },
"spec": { "spec": {
@ -223,6 +223,13 @@
} }
], ],
"parameters": [ "parameters": [
{
"name": "NAME",
"displayName": "Name",
"description": "The name assigned to all of the frontend objects defined in this template.",
"required": true,
"value": "django-example"
},
{ {
"name": "MEMORY_LIMIT", "name": "MEMORY_LIMIT",
"displayName": "Memory Limit", "displayName": "Memory Limit",