fix(nextgen): add PORT env var to deployment template and add host rules
This commit is contained in:
parent
5a606663d7
commit
63b731e931
|
|
@ -28,6 +28,8 @@ spec:
|
||||||
value: "/app/data/school.db"
|
value: "/app/data/school.db"
|
||||||
- name: JWT_SECRET
|
- name: JWT_SECRET
|
||||||
value: "africa-alert-production-secret-2024"
|
value: "africa-alert-production-secret-2024"
|
||||||
|
- name: ALLOWED_ORIGINS
|
||||||
|
value: "https://main.next-gen.techarvest.co.zw,https://next-gen.techarvest.co.zw,http://localhost:3000"
|
||||||
ports:
|
ports:
|
||||||
- name: http
|
- name: http
|
||||||
containerPort: 3001
|
containerPort: 3001
|
||||||
|
|
@ -70,6 +72,8 @@ spec:
|
||||||
value: "/app/data/school.db"
|
value: "/app/data/school.db"
|
||||||
- name: JWT_SECRET
|
- name: JWT_SECRET
|
||||||
value: "africa-alert-dev-secret-2024"
|
value: "africa-alert-dev-secret-2024"
|
||||||
|
- name: ALLOWED_ORIGINS
|
||||||
|
value: "https://dev.next-gen.techarvest.co.zw,http://localhost:3000"
|
||||||
ports:
|
ports:
|
||||||
- name: http
|
- name: http
|
||||||
containerPort: 3001
|
containerPort: 3001
|
||||||
|
|
@ -151,9 +155,20 @@ spec:
|
||||||
ingressClassName: nginx
|
ingressClassName: nginx
|
||||||
tls:
|
tls:
|
||||||
- hosts:
|
- hosts:
|
||||||
|
- main.next-gen.techarvest.co.zw
|
||||||
- next-gen.techarvest.co.zw
|
- next-gen.techarvest.co.zw
|
||||||
secretName: next-gen-main-tls
|
secretName: next-gen-main-tls
|
||||||
rules:
|
rules:
|
||||||
|
- host: main.next-gen.techarvest.co.zw
|
||||||
|
http:
|
||||||
|
paths:
|
||||||
|
- path: /
|
||||||
|
pathType: Prefix
|
||||||
|
backend:
|
||||||
|
service:
|
||||||
|
name: next-gen-main
|
||||||
|
port:
|
||||||
|
number: 80
|
||||||
- host: next-gen.techarvest.co.zw
|
- host: next-gen.techarvest.co.zw
|
||||||
http:
|
http:
|
||||||
paths:
|
paths:
|
||||||
|
|
|
||||||
|
|
@ -27,6 +27,15 @@ spec:
|
||||||
- name: http
|
- name: http
|
||||||
containerPort: {{ .Values.service.port }}
|
containerPort: {{ .Values.service.port }}
|
||||||
protocol: TCP
|
protocol: TCP
|
||||||
|
env:
|
||||||
|
- name: PORT
|
||||||
|
value: "{{ .Values.service.port }}"
|
||||||
|
- name: NODE_ENV
|
||||||
|
value: "production"
|
||||||
|
- name: DB_PATH
|
||||||
|
value: "/app/data/school.db"
|
||||||
|
- name: JWT_SECRET
|
||||||
|
value: "africa-alert-production-secret-2024"
|
||||||
resources:
|
resources:
|
||||||
{{- toYaml .Values.resources | nindent 12 }}
|
{{- toYaml .Values.resources | nindent 12 }}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue