Repository navigation
Fixes for restricted deck depl #85107
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
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,119 @@ | ||
| --- | ||
| apiVersion: apps/v1 | ||
| kind: Deployment | ||
| metadata: | ||
| labels: | ||
| app: gcsweb-test-platform-results | ||
| name: gcsweb-test-platform-results | ||
| namespace: ci | ||
| spec: | ||
| replicas: 2 | ||
| selector: | ||
| matchLabels: | ||
| component: gcsweb-test-platform-results | ||
| template: | ||
| metadata: | ||
| labels: | ||
| app: prow | ||
| component: gcsweb-test-platform-results | ||
| spec: | ||
| serviceAccountName: gcsweb-private | ||
| containers: | ||
| - args: | ||
| - -b | ||
| - test-platform-results | ||
| - --gcs-credentials-file=/etc/sa/credentials.json | ||
| image: quay.io/openshift/ci:ci_gcsweb_latest | ||
| name: gcsweb-test-platform-results | ||
| resources: | ||
| requests: | ||
| cpu: 50m | ||
| memory: 128Mi | ||
|
Comment on lines
+28
to
+31
Contributor
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. 🩺 Stability & Availability | 🟡 Minor | ⚡ Quick win Add CPU and memory limits to both containers. The 🧰 Tools🪛 Checkov (3.3.13)[medium] 2-83: Containers should not run with allowPrivilegeEscalation (CKV_K8S_20) [medium] 2-83: Minimize the admission of root containers (CKV_K8S_23) 🤖 Prompt for AI Agents |
||
| livenessProbe: | ||
| httpGet: | ||
| path: /healthz | ||
| port: 8081 | ||
| initialDelaySeconds: 10 | ||
| periodSeconds: 3 | ||
| readinessProbe: | ||
| httpGet: | ||
| path: /healthz/ready | ||
| port: 8081 | ||
| volumeMounts: | ||
| - mountPath: /etc/sa | ||
| name: gcs-credentials-file | ||
| readOnly: true | ||
| - args: | ||
| - -provider=openshift | ||
| - -https-address= | ||
| - -http-address=:4180 | ||
| - -email-domain=* | ||
| - -upstream=http://localhost:8080 | ||
| - -client-id=system:serviceaccount:ci:gcsweb-private | ||
| - -openshift-ca=/etc/pki/tls/cert.pem | ||
| - -openshift-ca=/var/run/secrets/kubernetes.io/serviceaccount/ca.crt | ||
| - -client-secret-file=/var/run/secrets/kubernetes.io/serviceaccount/token | ||
| - -cookie-secret-file=/etc/proxy/secrets/session_secret | ||
| - -cookie-samesite=none | ||
| - -cookie-secure=true | ||
| image: quay.io/openshift/origin-oauth-proxy:4.16 | ||
| imagePullPolicy: IfNotPresent | ||
| name: oauth-proxy | ||
| ports: | ||
| - containerPort: 4180 | ||
| name: web | ||
| readinessProbe: | ||
| tcpSocket: | ||
| port: 4180 | ||
|
Comment on lines
+65
to
+67
Contributor
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. 🩺 Stability & Availability | 🟡 Minor | ⚡ Quick win Add liveness and HTTP readiness probes for The 🧰 Tools🪛 Checkov (3.3.13)[medium] 2-83: Containers should not run with allowPrivilegeEscalation (CKV_K8S_20) [medium] 2-83: Minimize the admission of root containers (CKV_K8S_23) 🤖 Prompt for AI Agents |
||
| resources: | ||
| requests: | ||
| cpu: 50m | ||
| memory: 128Mi | ||
| volumeMounts: | ||
| - mountPath: /etc/proxy/secrets | ||
| name: session-secret | ||
| readOnly: true | ||
| volumes: | ||
| - name: gcs-credentials-file | ||
| secret: | ||
| secretName: test-platform-results-viewer | ||
| - name: session-secret | ||
| secret: | ||
| secretName: deck-internal-session-secret | ||
| --- | ||
| apiVersion: v1 | ||
| kind: Service | ||
| metadata: | ||
| labels: | ||
| app: prow | ||
| component: gcsweb-test-platform-results | ||
| name: gcsweb-test-platform-results | ||
| namespace: ci | ||
| spec: | ||
| ports: | ||
| - name: web | ||
| port: 80 | ||
| protocol: TCP | ||
| targetPort: 4180 | ||
| selector: | ||
| app: prow | ||
| component: gcsweb-test-platform-results | ||
| --- | ||
| apiVersion: route.openshift.io/v1 | ||
| kind: Route | ||
| metadata: | ||
| annotations: | ||
| haproxy.router.openshift.io/timeout: 1h | ||
| labels: | ||
| app: gcsweb-test-platform-results | ||
| name: gcsweb-test-platform-results | ||
| namespace: ci | ||
| spec: | ||
| port: | ||
| targetPort: web | ||
| tls: | ||
| insecureEdgeTerminationPolicy: Redirect | ||
| termination: edge | ||
| to: | ||
| kind: Service | ||
| name: gcsweb-test-platform-results | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -213,7 +213,7 @@ deck: | |
| bucket_aliases: | ||
| origin-ci-test: test-platform-results | ||
| gcs_browser_prefixes: | ||
| '*': https://gcsweb-private-ci.apps.ci.l2s4.p1.openshiftapps.com/gcs/ | ||
| '*': https://gcsweb-test-platform-results-ci.apps.ci.l2s4.p1.openshiftapps.com/gcs/ | ||
|
Contributor
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. 🗄️ Data Integrity & Integration | 🟡 Minor | ⚡ Quick win 🔎 Supported by static analysis🏁 Script executed: #!/bin/bash
set -eu
printf '%s\n' '--- changed file context ---'
sed -n '180,250p' core-services/prow/02_config/_config.yaml
printf '%s\n' '--- bucket and endpoint references ---'
rg -n -C 3 'origin-federated-results|prow-artifact-archive|test-platform-results-ci|gcsweb|Spyglass|spyglass' core-services/prow/02_config core-services/prow 2>/dev/null | head -n 300
printf '%s\n' '--- focused diff summary ---'
git diff --stat -- core-services/prow/02_config/_config.yaml
git diff -- core-services/prow/02_config/_config.yaml | sed -n '1,180p'Repository: openshift/release Length of output: 13855 🤖 get_repo_knowledge executed:
Length of output: 703 🏁 Script executed: #!/bin/bash
set -eu
printf '%s\n' '--- endpoint references across repository ---'
rg -n -C 4 'gcsweb-test-platform-results-ci|gcsweb-private-ci|gcs_browser_prefixes_by_bucket|gcs_browser_prefixes' . | head -n 400
printf '%s\n' '--- likely route/deployment references ---'
rg -n -C 3 'test-platform-results-ci|gcsweb|gcs-web|gcs.*browser|browser.*gcs' . | head -n 400
printf '%s\n' '--- relevant tracked paths ---'
git ls-files | rg '(^|/)(spyglass|gcs|prow|config|route|ingress)' | head -n 300Repository: openshift/release Length of output: 50375 🌐 Web query:
💡 Result: <search_synthesis> <source_evidence> Citations:
🏁 Script executed: #!/bin/bash
set -eu
cat -n clusters/app.ci/prow/03_deployment/gcsweb-test-platform-results.yaml | sed -n '1,150p'
printf '%s\n' '--- core gcsweb bucket arguments ---'
cat -n clusters/core-ci/gcsweb/gcsweb.yaml | sed -n '20,45p'Repository: openshift/release Length of output: 4889 Preserve bucket-specific Spyglass links. For repositories without an explicit 🤖 Prompt for AI Agents |
||
| openshift-eng/agent-qe-infra: https://gcsweb-qe-private-deck-ci.apps.ci.l2s4.p1.openshiftapps.com/gcs/ | ||
| openshift-eng/olm-team-ai-helpers: https://gcsweb-qe-private-deck-ci.apps.ci.l2s4.p1.openshiftapps.com/gcs/ | ||
| openshift-eng/ship-help-bot: https://gcsweb-qe-private-deck-ci.apps.ci.l2s4.p1.openshiftapps.com/gcs/ | ||
|
|
@@ -231,7 +231,7 @@ deck: | |
| openshift/openshift-tests-private: https://gcsweb-qe-private-deck-ci.apps.ci.l2s4.p1.openshiftapps.com/gcs/ | ||
| openshift/verification-tests: https://gcsweb-qe-private-deck-ci.apps.ci.l2s4.p1.openshiftapps.com/gcs/ | ||
| gcs_browser_prefixes_by_bucket: | ||
| '*': https://gcsweb-private-ci.apps.ci.l2s4.p1.openshiftapps.com/gcs/ | ||
| '*': https://gcsweb-test-platform-results-ci.apps.ci.l2s4.p1.openshiftapps.com/gcs/ | ||
| origin-ci-private: https://gcsweb-private-ci.apps.ci.l2s4.p1.openshiftapps.com/gcs/ | ||
| qe-private-deck: https://gcsweb-qe-private-deck-ci.apps.ci.l2s4.p1.openshiftapps.com/gcs/ | ||
| lenses: | ||
|
|
||
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.
🔒 Security & Privacy | 🛡️ Analyzed with Security Review | 🟠 Major | ⚡ Quick win
🧩 Analysis chain
🏁 Script executed:
Repository: openshift/release
Length of output: 4083
Security Misconfiguration
Reachability: External
CWE: CWE-16
Add container security contexts. Both containers omit the required security controls. Set
runAsNonRoot: true,readOnlyRootFilesystem: true, andallowPrivilegeEscalation: false. Drop all capabilities and add only capabilities that are demonstrably required.🧰 Tools
🪛 Checkov (3.3.13)
[medium] 2-83: Containers should not run with allowPrivilegeEscalation
(CKV_K8S_20)
[medium] 2-83: Minimize the admission of root containers
(CKV_K8S_23)
🤖 Prompt for AI Agents