added k8s files and jenkinsfile

This commit is contained in:
tusuii
2026-03-10 22:39:47 +05:30
parent 74918d251f
commit 57a2968d74
22 changed files with 767 additions and 1 deletions

View File

@@ -0,0 +1,45 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: backend
namespace: ecommerce
spec:
replicas: 1
selector:
matchLabels:
app: backend
template:
metadata:
labels:
app: backend
spec:
containers:
- name: backend
image: 192.168.49.2:30004/vaishnavi-ecommerce/backend:latest
imagePullPolicy: Always
ports:
- containerPort: 3000
envFrom:
- configMapRef:
name: backend-configmap
- secretRef:
name: backend-secret
resources:
requests:
cpu: "250m"
memory: "256Mi"
limits:
cpu: "500m"
memory: "512Mi"
livenessProbe:
httpGet:
path: /health
port: 3000
initialDelaySeconds: 30
periodSeconds: 15
readinessProbe:
httpGet:
path: /health
port: 3000
initialDelaySeconds: 10
periodSeconds: 5