From ade4943edc294101eb13a6218a9ab978c8263cc7 Mon Sep 17 00:00:00 2001 From: Kitarp29 Date: Fri, 18 Aug 2023 13:30:44 +0530 Subject: [PATCH] Upgarding the one-to-rule-them-all YAML Signed-off-by: Kitarp29 --- yamls/one-to-rule-them-all.yaml | 47 ++++++++++++++++++++------------- 1 file changed, 29 insertions(+), 18 deletions(-) diff --git a/yamls/one-to-rule-them-all.yaml b/yamls/one-to-rule-them-all.yaml index ce88396..fe39d74 100644 --- a/yamls/one-to-rule-them-all.yaml +++ b/yamls/one-to-rule-them-all.yaml @@ -18,24 +18,35 @@ roleRef: # referring to your ClusterRole name: cluster-admin # or the custom role you created in the last step apiGroup: rbac.authorization.k8s.io --- -apiVersion: v1 -kind: Pod +apiVersion: apps/v1 +kind: Deployment metadata: name: kube-ez spec: - serviceAccount: kube-ez - containers: - - name: kube-ez - image: kitarp29/k8s-api:latest - ports: - - containerPort: 8000 - securityContext: - allowPrivilegeEscalation: false - livenessProbe: - initialDelaySeconds: 60 - periodSeconds: 300 - successThreshold: 1 - failureThreshold: 3 - httpGet: - path: / - port: 8000 \ No newline at end of file + replicas: 1 + selector: + matchLabels: + app: kube-ez + template: + metadata: + labels: + app: kube-ez + spec: + serviceAccount: kube-ez + containers: + - name: kube-ez + image: kitarp29/k8s-api:10 + imagePullPolicy: Always + ports: + - containerPort: 8000 + securityContext: + allowPrivilegeEscalation: false + livenessProbe: + initialDelaySeconds: 60 + periodSeconds: 300 + successThreshold: 1 + failureThreshold: 3 + httpGet: + path: / + port: 8000 + restartPolicy: Always \ No newline at end of file