Commit e24f397c authored by Günter Hipler's avatar Günter Hipler
Browse files

added first k8s manifests

parent a0e65b09
Pipeline #10966 passed with stage
in 6 minutes and 7 seconds
apiVersion: apps/v1
kind: Deployment
metadata:
name: myName
\ No newline at end of file
apiVersion: apps/v1
kind: Deployment
metadata:
name: oai-prod-deployment
namespace: memobase
labels:
app: oai-prod-app
spec:
selector:
matchLabels:
app: oai-prod-app
replicas: 1
template:
metadata:
labels:
app: oai-prod-app
tier: web
spec:
serviceAccountName: oai-service-account #to be able to manage other pods inside the cluster
containers:
- name: oai-api-prod-container
image: cr.gitlab.switch.ch/memoriav/memobase-2020/services/externalapis/oai:0.4
ports:
- containerPort: 9000
name: http
protocol: TCP
imagePullPolicy: Always
apiVersion: networking.k8s.io/v1beta1
kind: Ingress
metadata:
namespace: memobase
name: memobase-api-ingress
annotations:
cert-manager.io/cluster-issuer: letsencrypt-prod
nginx.ingress.kubernetes.io/force-ssl-redirect: "true"
nginx.ingress.kubernetes.io/rewrite-target: /
spec:
tls:
- hosts:
- oai.memobase.k8s.unibas.ch
secretName: api.memobase.k8s.unibas.ch-tls
rules:
- host: oai.memobase.k8s.unibas.ch
http:
paths:
- path: /
backend:
serviceName: oai-api-prod
servicePort: 9000
\ No newline at end of file
apiVersion: v1
kind: Service
metadata:
namespace: memobase
name: oai-api-prod
labels:
app: oai-prod-app
spec:
ports:
- port: 9000
selector:
app: oai-prod-app
tier: web
clusterIP: None
\ No newline at end of file
* Abruf des containers
docker run -d --name oaifromgitlab -p 9000:9000 cr.gitlab.switch.ch/memoriav/memobase-2020/services/externalapis/oai:0.4
\ No newline at end of file
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