46 lines
996 B
YAML
46 lines
996 B
YAML
---
|
|
apiVersion: v1
|
|
kind: Service
|
|
metadata:
|
|
name: frontend
|
|
namespace: epcare
|
|
spec:
|
|
selector:
|
|
app: frontend
|
|
ports:
|
|
- name: http
|
|
protocol: TCP
|
|
port: 80
|
|
targetPort: 80
|
|
---
|
|
apiVersion: apps/v1
|
|
kind: Deployment
|
|
metadata:
|
|
name: frontend
|
|
namespace: epcare
|
|
spec:
|
|
replicas: 1
|
|
selector:
|
|
matchLabels:
|
|
app: frontend
|
|
template:
|
|
metadata:
|
|
labels:
|
|
app: frontend
|
|
spec:
|
|
nodeSelector:
|
|
kubernetes.io/hostname: NODE_HOSTNAME
|
|
imagePullSecrets:
|
|
- name: gitlab-registry
|
|
initContainers:
|
|
- name: wait-for-backend
|
|
image: busybox:1.36
|
|
command: ['sh', '-c', 'until nc -z backend 8080; do echo "waiting for backend..."; sleep 10; done']
|
|
containers:
|
|
- name: frontend
|
|
image: registry.gitlab.com/signalytic/client-external/epcare/frontend/arm64:1.1
|
|
imagePullPolicy: IfNotPresent
|
|
envFrom:
|
|
- secretRef:
|
|
name: frontend-env
|