Skip to content

Commit

Permalink
changes on k8s deployment WIP
Browse files Browse the repository at this point in the history
  • Loading branch information
10alejospain committed Dec 7, 2023
1 parent 1e29930 commit 6406d59
Show file tree
Hide file tree
Showing 13 changed files with 93 additions and 30 deletions.
5 changes: 4 additions & 1 deletion .dockerignore
Original file line number Diff line number Diff line change
@@ -1 +1,4 @@
*.md
*.md
.env
assets/*
kubernetes/*
14 changes: 14 additions & 0 deletions kubernetes/bare-kubernetes/002_connection-details.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: connection-details
data:
CELERY_BROKER_URL: "amqp://guest:guest@rabbitmq:5672/"
CELERY_RESULT_BACKEND: "db+postgresql://postgres:mysecretpassword@db/omopdb"
OMOP_DBMS: "postgresql"
OMOP_SERVER: "host.docker.internal"
OMOP_PORT: "5432"
OMOP_USER: "postgres"
OMOP_PASSWORD: "mysecretpassword"
OMOP_DATABASE: "omopdb"
OMOP_SCHEMA: "omopcdm"
60 changes: 60 additions & 0 deletions kubernetes/bare-kubernetes/005_ohdsi-api-deployment.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
#deployment of a api

apiVersion: apps/v1
kind: Deployment
metadata:
name: ohdsi-apit
labels:
app: ohdsi-api
spec:
replicas: 1
selector:
matchLabels:
app: ohdsi-api
template:
metadata:
labels:
app: ohdsi-api
spec:
containers:
- name: ohdsi-api
image: ohdsi-api:latest
imagePullPolicy: IfNotPresent
ports:
- containerPort: 8080
env:
- name: OMOP_DBMS
valueFrom:
configMapKeyRef:
name: connection-details
key: OMOP_DBMS
- name: OMOP_SERVER
valueFrom:
configMapKeyRef:
name: connection-details
key: OMOP_SERVER
- name: OMOP_PORT
valueFrom:
configMapKeyRef:
name: connection-details
key: OMOP_PORT
- name: OMOP_USER
valueFrom:
secretKeyRef:
name: omop-secrets
key: POSTGRES_USER
- name: OMOP_PASSWORD
valueFrom:
secretKeyRef:
name: omop-secrets
key: POSTGRES_PASSWORD
- name: OMOP_DATABASE
valueFrom:
configMapKeyRef:
name: connection-details
key: OMOP_DATABASE
- name: OMOP_SCHEMA
valueFrom:
configMapKeyRef:
name: connection-details
key: OMOP_SCHEMA
6 changes: 0 additions & 6 deletions kubernetes/istio/001_datamesh-ns.yaml

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,5 @@ metadata:
namespace: datamesh
type: Opaque
data:
POSTGRES_USER: cG9zdGdyZXM= # postgres in base64
POSTGRES_PASSWORD: bXlzZWNyZXRwYXNzd29yZA== # mysecretpassword in base64
14 changes: 14 additions & 0 deletions kubernetes/istio/002_connection-details.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: connection-details
data:
CELERY_BROKER_URL: "amqp://guest:guest@rabbitmq:5672/"
CELERY_RESULT_BACKEND: "db+postgresql://postgres:mysecretpassword@db/omopdb"
OMOP_DBMS: "postgresql"
OMOP_SERVER: "host.docker.internal"
OMOP_PORT: "5432"
OMOP_USER: "postgres"
OMOP_PASSWORD: "mysecretpassword"
OMOP_DATABASE: "omopdb"
OMOP_SCHEMA: "omopcdm"
8 changes: 0 additions & 8 deletions kubernetes/istio/002_mtls-policy.yaml

This file was deleted.

15 changes: 0 additions & 15 deletions kubernetes/istio/003_gateway.yaml

This file was deleted.

File renamed without changes.

0 comments on commit 6406d59

Please sign in to comment.