uploaded k8s and jenkinsfile
Some checks failed
ecommerce admin pannel/pipeline/head Something is wrong with the build of this commit

This commit is contained in:
tusuii
2026-03-10 22:38:39 +05:30
parent 39d42663c0
commit 14b4099cdf
6 changed files with 191 additions and 4 deletions

40
k8s/deployment.yaml Normal file
View File

@@ -0,0 +1,40 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: admin
namespace: ecommerce
spec:
replicas: 1
selector:
matchLabels:
app: admin
template:
metadata:
labels:
app: admin
spec:
containers:
- name: admin
image: 192.168.49.2:30004/vaishnavi-ecommerce/admin:latest
imagePullPolicy: Always
ports:
- containerPort: 80
resources:
requests:
cpu: "100m"
memory: "64Mi"
limits:
cpu: "250m"
memory: "128Mi"
livenessProbe:
httpGet:
path: /
port: 80
initialDelaySeconds: 10
periodSeconds: 15
readinessProbe:
httpGet:
path: /
port: 80
initialDelaySeconds: 5
periodSeconds: 5

20
k8s/ingress.yaml Normal file
View File

@@ -0,0 +1,20 @@
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: admin-ingress
namespace: ecommerce
annotations:
nginx.ingress.kubernetes.io/proxy-body-size: "10m"
spec:
ingressClassName: nginx
rules:
- host: admin.local
http:
paths:
- path: /
pathType: Prefix
backend:
service:
name: admin
port:
number: 80

13
k8s/service.yaml Normal file
View File

@@ -0,0 +1,13 @@
apiVersion: v1
kind: Service
metadata:
name: admin
namespace: ecommerce
spec:
type: NodePort
selector:
app: admin
ports:
- port: 80
targetPort: 80
nodePort: 30082