spring-web-modules/k8s/06-app.yaml
Sambo Chea f6c0a31fc1
All checks were successful
continuous-integration/drone/push Build is passing
Updated app k8s
2022-04-11 13:00:05 +07:00

55 lines
1.2 KiB
YAML

apiVersion: v1
kind: Service
metadata:
namespace: spring-web-dev
name: spring-web-service
spec:
selector:
app: spring-web-api
ports:
- port: 8080
targetPort: 8080
type: ClusterIP
---
apiVersion: apps/v1
kind: Deployment
metadata:
namespace: spring-web-dev
name: spring-web-deployment
spec:
replicas: 1
selector:
matchLabels:
app: spring-web-api
template:
metadata:
labels:
app: spring-web-api
spec:
imagePullSecrets:
- name: registry-secret
containers:
- name: spring-web-api
image: registry.kh.cubetiqs.com/spring-web-api:demo
ports:
- containerPort: 8080
envFrom:
- secretRef:
name: spring-web-dev-secret
volumeMounts:
- name: spring-web-api-data
mountPath: /opt/cubetiq/data
subPath: spring-web-api-data
imagePullPolicy: Always
resources:
requests:
cpu: 300m
memory: 300Mi
limits:
cpu: 800m
memory: 800Mi
volumes:
- name: spring-web-api-data
persistentVolumeClaim:
claimName: spring-web-dev-volume