commit 824a3ec8de9564b20e108a72483671d71d43925f Author: gitea_admin Date: Mon Feb 16 16:33:27 2026 +0000 deployment yaml file diff --git a/k8s/deployment.yaml b/k8s/deployment.yaml new file mode 100644 index 0000000..409ab6c --- /dev/null +++ b/k8s/deployment.yaml @@ -0,0 +1,44 @@ +apiVersion: apps/v1 +kind: Deployment +metadata: + name: nodejs-app + namespace: apps +spec: + replicas: 2 + selector: + matchLabels: + app: nodejs-app + template: + metadata: + labels: + app: nodejs-app + spec: + imagePullSecrets: + - name: harbor-secret + containers: + - name: nodejs-app + image: /library/nodejs-app:1 + ports: + - containerPort: 3000 + env: + - name: APP_VERSION + value: "1.0.0" + livenessProbe: + httpGet: + path: /health + port: 3000 + initialDelaySeconds: 10 + periodSeconds: 10 + readinessProbe: + httpGet: + path: /health + port: 3000 + initialDelaySeconds: 5 + periodSeconds: 5 + resources: + requests: + cpu: "50m" + memory: "64Mi" + limits: + cpu: "200m" + memory: "128Mi" \ No newline at end of file