Commit 05db7c99 authored by Mohamed, Fawzi Roberto (fawzi)'s avatar Mohamed, Fawzi Roberto (fawzi)
Browse files

kubernetes deploy of api

parent a64de66b
{
"kind": "Service",
"apiVersion": "v1",
"metadata": {
"name": "api-svc",
"labels": {
"config": "${config}",
"app": "nomad-api-server"
}
},
"spec":{
"type": "NodePort",
"ports":[{
"port": 8088,
"name": "api-port",
"targetPort": 8081,
"protocol": "TCP"
}],
"selector":{
"config": "${config}",
"app": "nomad-api-server"
}
}
}
apiVersion: v1
kind: ReplicationController
---
apiVersion: apps/v1beta2
kind: Deployment
metadata:
name: archive-webservice-dev
labels:
config: "${config}"
user: ${user}
component: archive-webservice
spec:
replicas: 1
selector:
config: "${config}"
app: archive-webservice-dev
matchLabels:
app: archive-webservice-dev
template:
metadata:
labels:
......@@ -17,8 +19,10 @@ spec:
config: "${config}"
app: archive-webservice-dev
spec:
imagePullSecrets:
- name: garching-kube
containers:
- image: labdev-nomad.esc.rzg.mpg.de:5000/nomadlab/archivewebservice:v${version}
- image: "analytics-toolkit.nomad-coe.eu:5509/nomadlab/archivewebservice:v${version}"
name: archive-webservice
env:
- name: NOMAD_ENV
......
apiVersion: v1
kind: ReplicationController
---
apiVersion: apps/v1beta2
kind: Deployment
metadata:
name: archive-webservice-rc
name: archive-webservice
labels:
config: "${config}"
user: ${user}
component: archive-webservice
spec:
replicas: 1
selector:
config: "${config}"
app: archive-webservice
matchLabels:
app: archive-webservice
template:
metadata:
labels:
......@@ -17,12 +19,14 @@ spec:
config: "${config}"
app: archive-webservice
spec:
imagePullSecrets:
- name: garching-kube
containers:
- image: labdev-nomad.esc.rzg.mpg.de:5000/nomadlab/archivewebservice:v${version}
- image: "analytics-toolkit.nomad-coe.eu:5509/nomadlab/archivewebservice:v${version}"
name: archive-webservice
env:
- name: NOMAD_ENV
value: "${config}"
imagePullPolicy: IfNotPresent
ports:
- containerPort: 8112
\ No newline at end of file
- containerPort: 8112
apiVersion: "v1"
kind: "ReplicationController"
---
apiVersion: apps/v1beta2
kind: Deployment
metadata:
name: "api-rc-${config}"
name: "resolve-api"
labels:
user: ${user}
config: "${config}"
app: "nomad-api-server"
app: "resolve-api"
spec:
replicas: 1
selector:
config: "${config}"
app: "nomad-api-server"
matchLabels:
app: resolve-api
template:
metadata:
labels:
user: ${user}
config: "${config}"
app: "nomad-api-server"
app: resolve-api
spec:
imagePullSecrets:
- name: garching-kube
......@@ -51,12 +54,6 @@ spec:
- mountPath: "${nomad_lab.roots.normalizedRoot}"
name: "normalized-data-volume"
readOnly: true
- mountPath: "/temporary-downloads"
name: "temporary-downloads-data-volume"
readOnly: false
- mountPath: "/scripts"
name: "scripts-data-volume"
readOnly: true
volumes:
- name: "parsed-data-volume"
hostPath:
......@@ -67,9 +64,3 @@ spec:
- name: "normalized-data-volume"
hostPath:
path: "${nomad_lab.hostPaths.normalizedRoot}"
- name: "temporary-downloads-data-volume"
hostPath:
path: "${nomad_lab.hostPaths.baseSharedTmp}/webservice-${config}"
- name: "scripts-data-volume"
hostPath:
path: "${nomad_lab.hostPaths.baseSharedTmp}/scripts-${config}"
kind: Service
apiVersion: v1
metadata:
name: "resolve-api"
labels:
user: ${user}
config: "${config}"
app: resolve-api
spec:
type: NodePort
ports:
- port: 8088
name: "api-port"
targetPort: 8081
protocol: "TCP"
selector:
app: "resolve-api"
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment