Merge pull request #5 from sspeiche/alignment
Parameterize service and routes consistently
This commit is contained in:
commit
858fbbf3c9
1 changed files with 15 additions and 10 deletions
|
@ -4,7 +4,7 @@
|
||||||
"metadata": {
|
"metadata": {
|
||||||
"name": "nodejs-example",
|
"name": "nodejs-example",
|
||||||
"annotations": {
|
"annotations": {
|
||||||
"description": "A simple Node.js application that responds with information about the server.",
|
"description": "A simple Node.js application with no database",
|
||||||
"iconClass": "icon-nodejs",
|
"iconClass": "icon-nodejs",
|
||||||
"tags": "instant-app,nodejs"
|
"tags": "instant-app,nodejs"
|
||||||
}
|
}
|
||||||
|
@ -14,7 +14,7 @@
|
||||||
"kind": "Service",
|
"kind": "Service",
|
||||||
"apiVersion": "v1",
|
"apiVersion": "v1",
|
||||||
"metadata": {
|
"metadata": {
|
||||||
"name": "nodejs-frontend"
|
"name": "${FRONTEND_SERVICE_NAME}"
|
||||||
},
|
},
|
||||||
"spec": {
|
"spec": {
|
||||||
"ports": [
|
"ports": [
|
||||||
|
@ -25,7 +25,7 @@
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"selector": {
|
"selector": {
|
||||||
"name": "nodejs-frontend"
|
"name": "${FRONTEND_SERVICE_NAME}"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -33,13 +33,13 @@
|
||||||
"kind": "Route",
|
"kind": "Route",
|
||||||
"apiVersion": "v1",
|
"apiVersion": "v1",
|
||||||
"metadata": {
|
"metadata": {
|
||||||
"name": "frontend-route"
|
"name": "${FRONTEND_ROUTE}"
|
||||||
},
|
},
|
||||||
"spec": {
|
"spec": {
|
||||||
"host" : "${FRONTEND_ROUTE}",
|
"host" : "${FRONTEND_ROUTE}",
|
||||||
"to": {
|
"to": {
|
||||||
"kind" : "Service",
|
"kind" : "Service",
|
||||||
"name" : "nodejs-frontend"
|
"name" : "${FRONTEND_SERVICE_NAME}"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -143,12 +143,12 @@
|
||||||
],
|
],
|
||||||
"replicas": 1,
|
"replicas": 1,
|
||||||
"selector": {
|
"selector": {
|
||||||
"name": "nodejs-frontend"
|
"name": "nodejs-example"
|
||||||
},
|
},
|
||||||
"template": {
|
"template": {
|
||||||
"metadata": {
|
"metadata": {
|
||||||
"labels": {
|
"labels": {
|
||||||
"name": "nodejs-frontend"
|
"name": "nodejs-example"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"spec": {
|
"spec": {
|
||||||
|
@ -171,12 +171,17 @@
|
||||||
"parameters": [
|
"parameters": [
|
||||||
{
|
{
|
||||||
"name": "SOURCE_REPOSITORY_URL",
|
"name": "SOURCE_REPOSITORY_URL",
|
||||||
"description": "The URL with your Node.js application source code.",
|
"description": "The URL with your Node.js application source code",
|
||||||
"value": "https://github.com/openshift/nodejs-ex.git"
|
"value": "https://github.com/openshift/nodejs-ex.git"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "FRONTEND_SERVICE_NAME",
|
||||||
|
"description": "Frontend service name",
|
||||||
|
"value": "nodejs"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "FRONTEND_ROUTE",
|
"name": "FRONTEND_ROUTE",
|
||||||
"description": "The exposed hostname that will route to the Node.js service.",
|
"description": "The exposed hostname that will route to the Node.js service",
|
||||||
"value": "nodejs.apps"
|
"value": "nodejs.apps"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
|
Loading…
Reference in a new issue