Skip to content

Commit 56f0a1e

Browse files
committed
Move helm and deployment plan to infra folder
1 parent bc13dad commit 56f0a1e

22 files changed

Lines changed: 151 additions & 209 deletions
File renamed without changes.

ums-helm/templates/backend-deployment.yaml renamed to infra/ums-helm/templates/backend-deployment.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ spec:
1717
containers:
1818
- name: ums-backend
1919
image: ums/backend:latest
20+
imagePullPolicy: IfNotPresent
2021
env:
2122
- name: ASPNETCORE_ENVIRONMENT
2223
value: Production
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
apiVersion: v1
2+
kind: Service
3+
metadata:
4+
name: ums-backend
5+
spec:
6+
type: ClusterIP
7+
selector:
8+
app: ums-backend
9+
ports:
10+
- protocol: TCP
11+
port: 80
12+
targetPort: 80
Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
apiVersion: apps/v1
2+
kind: Deployment
3+
metadata:
4+
name: ums-frontend
5+
labels:
6+
app: ums-frontend
7+
spec:
8+
replicas: 1
9+
selector:
10+
matchLabels:
11+
app: ums-frontend
12+
template:
13+
metadata:
14+
labels:
15+
app: ums-frontend
16+
spec:
17+
containers:
18+
- name: ums-frontend
19+
image: ums/frontend:latest
20+
imagePullPolicy: IfNotPresent
21+
ports:
22+
- containerPort: 80
23+
resources:
24+
limits:
25+
cpu: "200m"
26+
memory: "256Mi"
27+
requests:
28+
cpu: "100m"
29+
memory: "128Mi"
30+
---
31+
apiVersion: v1
32+
kind: Service
33+
metadata:
34+
name: ums-frontend
35+
spec:
36+
type: ClusterIP
37+
selector:
38+
app: ums-frontend
39+
ports:
40+
- protocol: TCP
41+
port: 80
42+
targetPort: 80
Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
apiVersion: apps/v1
2+
kind: Deployment
3+
metadata:
4+
name: ums-postgres
5+
spec:
6+
replicas: 1
7+
selector:
8+
matchLabels:
9+
app: ums-postgres
10+
template:
11+
metadata:
12+
labels:
13+
app: ums-postgres
14+
spec:
15+
containers:
16+
- name: postgres
17+
image: postgres:15-alpine
18+
env:
19+
- name: POSTGRES_USER
20+
value: postgres
21+
- name: POSTGRES_PASSWORD
22+
valueFrom:
23+
secretKeyRef:
24+
name: ums-db-secret
25+
key: POSTGRES_PASSWORD
26+
- name: POSTGRES_DB
27+
value: ums
28+
ports:
29+
- containerPort: 5432
30+
volumeMounts:
31+
- name: pgdata
32+
mountPath: /var/lib/postgresql/data
33+
volumes:
34+
- name: pgdata
35+
emptyDir: {}
36+
---
37+
apiVersion: v1
38+
kind: Service
39+
metadata:
40+
name: ums-postgres
41+
spec:
42+
type: ClusterIP
43+
selector:
44+
app: ums-postgres
45+
ports:
46+
- protocol: TCP
47+
port: 5432
48+
targetPort: 5432

0 commit comments

Comments
 (0)