فهرست منبع

chore: update nginx deployment

* add cpu and memory requests
* increase replicas to 2
* update security context for 4.11
Samuel Padgett 4 سال پیش
والد
کامیت
e27295e1d5
1فایلهای تغییر یافته به همراه14 افزوده شده و 1 حذف شده
  1. 14 1
      template.yaml

+ 14 - 1
template.yaml

@@ -46,7 +46,7 @@ objects:
         app.kubernetes.io/part-of: '${PLUGIN_NAME}'
         app.openshift.io/runtime-namespace: '${NAMESPACE}'
     spec:
-      replicas: 1
+      replicas: 2
       selector:
         matchLabels:
           app: '${PLUGIN_NAME}'
@@ -62,6 +62,15 @@ objects:
                 - containerPort: 9443
                   protocol: TCP
               imagePullPolicy: Always
+              securityContext:
+                allowPrivilegeEscalation: false
+                capabilities:
+                  drop:
+                  - ALL
+              resources:
+                  requests:
+                    cpu: 10m
+                    memory: 50Mi
               volumeMounts:
                 - name: plugin-serving-cert
                   readOnly: true
@@ -81,6 +90,10 @@ objects:
                 defaultMode: 420
           restartPolicy: Always
           dnsPolicy: ClusterFirst
+          securityContext:
+            runAsNonRoot: true
+            seccompProfile:
+              type: RuntimeDefault
       strategy:
         type: RollingUpdate
         rollingUpdate: