-
Notifications
You must be signed in to change notification settings - Fork 236
OTA-1956: testing install: Split multi-document YAML and add missing annotations #1398
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,15 @@ | ||
| apiVersion: v1 | ||
| kind: Namespace | ||
| metadata: | ||
| name: openshift-cluster-update-console-plugin | ||
| annotations: | ||
| kubernetes.io/description: The OpenShift cluster-update console plugin provides a web-console interface for managing ClusterVersion updates. | ||
| capability.openshift.io/name: Console | ||
| release.openshift.io/feature-set: TechPreviewNoUpgrade | ||
| exclude.release.openshift.io/internal-openshift-hosted: "true" | ||
| include.release.openshift.io/self-managed-high-availability: "true" | ||
| labels: | ||
| openshift.io/cluster-monitoring: "true" | ||
| pod-security.kubernetes.io/audit: restricted | ||
| pod-security.kubernetes.io/enforce: restricted | ||
| pod-security.kubernetes.io/warn: restricted |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,11 @@ | ||
| apiVersion: v1 | ||
| kind: ServiceAccount | ||
| metadata: | ||
| name: cluster-update-console-plugin | ||
| namespace: openshift-cluster-update-console-plugin | ||
| annotations: | ||
| kubernetes.io/description: The OpenShift cluster-update console plugin provides a web-console interface for managing ClusterVersion updates. | ||
| capability.openshift.io/name: Console | ||
| release.openshift.io/feature-set: TechPreviewNoUpgrade | ||
| exclude.release.openshift.io/internal-openshift-hosted: "true" | ||
| include.release.openshift.io/self-managed-high-availability: "true" |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,16 @@ | ||
| apiVersion: networking.k8s.io/v1 | ||
| kind: NetworkPolicy | ||
| metadata: | ||
| name: default-deny | ||
| namespace: openshift-cluster-update-console-plugin | ||
| annotations: | ||
| kubernetes.io/description: This NetworkPolicy is used to deny all ingress and egress traffic by default in this namespace, matching all Pods, and serving as a baseline. | ||
| capability.openshift.io/name: Console | ||
| release.openshift.io/feature-set: TechPreviewNoUpgrade | ||
| exclude.release.openshift.io/internal-openshift-hosted: "true" | ||
| include.release.openshift.io/self-managed-high-availability: "true" | ||
| spec: | ||
| podSelector: {} | ||
| policyTypes: | ||
| - Ingress | ||
| - Egress | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,28 @@ | ||
| apiVersion: v1 | ||
| kind: ConfigMap | ||
| metadata: | ||
| name: cluster-update-console-plugin | ||
| namespace: openshift-cluster-update-console-plugin | ||
| annotations: | ||
| kubernetes.io/description: Nginx configuration for the cluster-update console plugin. | ||
| capability.openshift.io/name: Console | ||
| release.openshift.io/feature-set: TechPreviewNoUpgrade | ||
| exclude.release.openshift.io/internal-openshift-hosted: "true" | ||
| include.release.openshift.io/self-managed-high-availability: "true" | ||
| data: | ||
| nginx.conf: | | ||
| error_log /dev/stderr; | ||
| events {} | ||
| http { | ||
| access_log /dev/stdout; | ||
| include /etc/nginx/mime.types; | ||
| default_type application/octet-stream; | ||
| keepalive_timeout 65; | ||
| server { | ||
| listen 9001 ssl; | ||
| listen [::]:9001 ssl; | ||
| ssl_certificate /var/cert/tls.crt; | ||
| ssl_certificate_key /var/cert/tls.key; | ||
| root /usr/share/nginx/html; | ||
| } | ||
| } |
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,78 @@ | ||||||||||||||||||||||||||||||||||||||||||||||||||
| apiVersion: apps/v1 | ||||||||||||||||||||||||||||||||||||||||||||||||||
| kind: Deployment | ||||||||||||||||||||||||||||||||||||||||||||||||||
| metadata: | ||||||||||||||||||||||||||||||||||||||||||||||||||
| name: cluster-update-console-plugin | ||||||||||||||||||||||||||||||||||||||||||||||||||
| namespace: openshift-cluster-update-console-plugin | ||||||||||||||||||||||||||||||||||||||||||||||||||
| annotations: | ||||||||||||||||||||||||||||||||||||||||||||||||||
| kubernetes.io/description: The OpenShift cluster-update console plugin provides a web-console interface for managing ClusterVersion updates. | ||||||||||||||||||||||||||||||||||||||||||||||||||
| capability.openshift.io/name: Console | ||||||||||||||||||||||||||||||||||||||||||||||||||
| release.openshift.io/feature-set: TechPreviewNoUpgrade | ||||||||||||||||||||||||||||||||||||||||||||||||||
| exclude.release.openshift.io/internal-openshift-hosted: "true" | ||||||||||||||||||||||||||||||||||||||||||||||||||
| include.release.openshift.io/self-managed-high-availability: "true" | ||||||||||||||||||||||||||||||||||||||||||||||||||
| spec: | ||||||||||||||||||||||||||||||||||||||||||||||||||
| selector: | ||||||||||||||||||||||||||||||||||||||||||||||||||
| matchLabels: | ||||||||||||||||||||||||||||||||||||||||||||||||||
| app: cluster-update-console-plugin | ||||||||||||||||||||||||||||||||||||||||||||||||||
| strategy: | ||||||||||||||||||||||||||||||||||||||||||||||||||
| rollingUpdate: | ||||||||||||||||||||||||||||||||||||||||||||||||||
| maxSurge: 25% | ||||||||||||||||||||||||||||||||||||||||||||||||||
| maxUnavailable: 1 | ||||||||||||||||||||||||||||||||||||||||||||||||||
| type: RollingUpdate | ||||||||||||||||||||||||||||||||||||||||||||||||||
| template: | ||||||||||||||||||||||||||||||||||||||||||||||||||
| metadata: | ||||||||||||||||||||||||||||||||||||||||||||||||||
| annotations: | ||||||||||||||||||||||||||||||||||||||||||||||||||
| target.workload.openshift.io/management: '{"effect": "PreferredDuringScheduling"}' | ||||||||||||||||||||||||||||||||||||||||||||||||||
| openshift.io/required-scc: restricted-v3 | ||||||||||||||||||||||||||||||||||||||||||||||||||
| labels: | ||||||||||||||||||||||||||||||||||||||||||||||||||
| app: cluster-update-console-plugin | ||||||||||||||||||||||||||||||||||||||||||||||||||
| spec: | ||||||||||||||||||||||||||||||||||||||||||||||||||
| serviceAccountName: cluster-update-console-plugin | ||||||||||||||||||||||||||||||||||||||||||||||||||
| automountServiceAccountToken: false | ||||||||||||||||||||||||||||||||||||||||||||||||||
| containers: | ||||||||||||||||||||||||||||||||||||||||||||||||||
| - name: plugin | ||||||||||||||||||||||||||||||||||||||||||||||||||
| image: '{{index .Images "cluster-update-console-plugin"}}' | ||||||||||||||||||||||||||||||||||||||||||||||||||
| imagePullPolicy: IfNotPresent | ||||||||||||||||||||||||||||||||||||||||||||||||||
| ports: | ||||||||||||||||||||||||||||||||||||||||||||||||||
| - name: https | ||||||||||||||||||||||||||||||||||||||||||||||||||
| containerPort: 9001 | ||||||||||||||||||||||||||||||||||||||||||||||||||
| resources: | ||||||||||||||||||||||||||||||||||||||||||||||||||
|
coderabbitai[bot] marked this conversation as resolved.
|
||||||||||||||||||||||||||||||||||||||||||||||||||
| requests: | ||||||||||||||||||||||||||||||||||||||||||||||||||
| cpu: 20m | ||||||||||||||||||||||||||||||||||||||||||||||||||
| memory: 50Mi | ||||||||||||||||||||||||||||||||||||||||||||||||||
| securityContext: | ||||||||||||||||||||||||||||||||||||||||||||||||||
| allowPrivilegeEscalation: false | ||||||||||||||||||||||||||||||||||||||||||||||||||
| capabilities: | ||||||||||||||||||||||||||||||||||||||||||||||||||
| drop: | ||||||||||||||||||||||||||||||||||||||||||||||||||
| - ALL | ||||||||||||||||||||||||||||||||||||||||||||||||||
| terminationMessagePolicy: FallbackToLogsOnError | ||||||||||||||||||||||||||||||||||||||||||||||||||
|
Comment on lines
+38
to
+47
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Add container limits and read-only root filesystem. Container Suggested patch resources:
requests:
cpu: 20m
memory: 50Mi
+ limits:
+ cpu: 100m
+ memory: 200Mi
securityContext:
allowPrivilegeEscalation: false
+ readOnlyRootFilesystem: true
capabilities:
drop:
- ALLAs per coding guidelines, 📝 Committable suggestion
Suggested change
🤖 Prompt for AI Agents |
||||||||||||||||||||||||||||||||||||||||||||||||||
| volumeMounts: | ||||||||||||||||||||||||||||||||||||||||||||||||||
| - mountPath: /var/cert | ||||||||||||||||||||||||||||||||||||||||||||||||||
| name: cluster-update-console-plugin-cert | ||||||||||||||||||||||||||||||||||||||||||||||||||
| readOnly: true | ||||||||||||||||||||||||||||||||||||||||||||||||||
| - mountPath: /etc/nginx/nginx.conf | ||||||||||||||||||||||||||||||||||||||||||||||||||
| name: nginx-conf | ||||||||||||||||||||||||||||||||||||||||||||||||||
| readOnly: true | ||||||||||||||||||||||||||||||||||||||||||||||||||
| subPath: nginx.conf | ||||||||||||||||||||||||||||||||||||||||||||||||||
| dnsPolicy: ClusterFirst | ||||||||||||||||||||||||||||||||||||||||||||||||||
| hostUsers: false | ||||||||||||||||||||||||||||||||||||||||||||||||||
| nodeSelector: | ||||||||||||||||||||||||||||||||||||||||||||||||||
| kubernetes.io/os: linux | ||||||||||||||||||||||||||||||||||||||||||||||||||
| priorityClassName: system-cluster-critical | ||||||||||||||||||||||||||||||||||||||||||||||||||
| securityContext: | ||||||||||||||||||||||||||||||||||||||||||||||||||
| runAsNonRoot: true | ||||||||||||||||||||||||||||||||||||||||||||||||||
| seccompProfile: | ||||||||||||||||||||||||||||||||||||||||||||||||||
| type: RuntimeDefault | ||||||||||||||||||||||||||||||||||||||||||||||||||
| terminationGracePeriodSeconds: 30 | ||||||||||||||||||||||||||||||||||||||||||||||||||
| tolerations: | ||||||||||||||||||||||||||||||||||||||||||||||||||
| - effect: NoSchedule | ||||||||||||||||||||||||||||||||||||||||||||||||||
| key: node-role.kubernetes.io/infra | ||||||||||||||||||||||||||||||||||||||||||||||||||
| operator: Exists | ||||||||||||||||||||||||||||||||||||||||||||||||||
| volumes: | ||||||||||||||||||||||||||||||||||||||||||||||||||
| - name: cluster-update-console-plugin-cert | ||||||||||||||||||||||||||||||||||||||||||||||||||
| secret: | ||||||||||||||||||||||||||||||||||||||||||||||||||
| defaultMode: 420 | ||||||||||||||||||||||||||||||||||||||||||||||||||
| secretName: cluster-update-console-plugin-cert | ||||||||||||||||||||||||||||||||||||||||||||||||||
| - name: nginx-conf | ||||||||||||||||||||||||||||||||||||||||||||||||||
| configMap: | ||||||||||||||||||||||||||||||||||||||||||||||||||
| name: cluster-update-console-plugin | ||||||||||||||||||||||||||||||||||||||||||||||||||
| defaultMode: 420 | ||||||||||||||||||||||||||||||||||||||||||||||||||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,20 @@ | ||
| apiVersion: v1 | ||
| kind: Service | ||
| metadata: | ||
| name: openshift-cluster-update-console-plugin | ||
| namespace: openshift-cluster-update-console-plugin | ||
| annotations: | ||
| kubernetes.io/description: The OpenShift cluster-update console plugin provides a web-console interface for managing ClusterVersion updates. | ||
| service.beta.openshift.io/serving-cert-secret-name: cluster-update-console-plugin-cert | ||
| capability.openshift.io/name: Console | ||
| release.openshift.io/feature-set: TechPreviewNoUpgrade | ||
| exclude.release.openshift.io/internal-openshift-hosted: "true" | ||
| include.release.openshift.io/self-managed-high-availability: "true" | ||
|
coderabbitai[bot] marked this conversation as resolved.
|
||
| spec: | ||
| type: ClusterIP | ||
| selector: | ||
| app: cluster-update-console-plugin | ||
| ports: | ||
| - name: https | ||
| port: 9001 | ||
| targetPort: https | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,21 @@ | ||
| apiVersion: console.openshift.io/v1 | ||
| kind: ConsolePlugin | ||
| metadata: | ||
| name: openshift-cluster-update-console-plugin | ||
| annotations: | ||
| kubernetes.io/description: The OpenShift cluster-update console plugin provides a web-console interface for managing ClusterVersion updates. | ||
| capability.openshift.io/name: Console | ||
| release.openshift.io/feature-set: TechPreviewNoUpgrade | ||
| exclude.release.openshift.io/internal-openshift-hosted: "true" | ||
| include.release.openshift.io/self-managed-high-availability: "true" | ||
| spec: | ||
| displayName: Cluster Updates | ||
| i18n: | ||
| loadType: Preload | ||
| backend: | ||
| type: Service | ||
| service: | ||
| name: openshift-cluster-update-console-plugin | ||
| namespace: openshift-cluster-update-console-plugin | ||
| port: 9001 | ||
| basePath: / |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,8 @@ | ||
| kind: ImageStream | ||
| apiVersion: image.openshift.io/v1 | ||
| spec: | ||
| tags: | ||
| - name: cluster-update-console-plugin | ||
| from: | ||
| kind: DockerImage | ||
| name: placeholder.url.oc.will.replace.this.example.org:cluster-update-console-plugin |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Default-deny policy blocks plugin traffic without companion allow policies.
podSelector: {}+Ingress/Egresswith no rules denies all traffic. As-is, backend access to the plugin service (and monitoring ingress) will be blocked unless additional allow policies are added in this namespace.🤖 Prompt for AI Agents