Skip to content

Commit

Permalink
feat: update prow to latest version (#197)
Browse files Browse the repository at this point in the history
* feat: update prow to latest version

Signed-off-by: Georgi Ivanov <[email protected]>

* feat: update cronjob api version and fix hook ingress

Signed-off-by: Georgi Ivanov <[email protected]>

Signed-off-by: Georgi Ivanov <[email protected]>
  • Loading branch information
givanov authored Aug 15, 2022
1 parent 5a9542a commit ff24643
Show file tree
Hide file tree
Showing 21 changed files with 847 additions and 467 deletions.
2 changes: 1 addition & 1 deletion prow/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,4 @@ type: application
version: 0.0.0

# Uses the Prow version
appVersion: v20200610-6c96a0a6ed
appVersion: v20220810-4ab15cddef
928 changes: 632 additions & 296 deletions prow/crds/00-coreos.servicemonitor.yaml

Large diffs are not rendered by default.

151 changes: 80 additions & 71 deletions prow/crds/00-prowjob.yaml
Original file line number Diff line number Diff line change
@@ -1,87 +1,96 @@
---
apiVersion: apiextensions.k8s.io/v1beta1
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
name: prowjobs.prow.k8s.io
annotations:
"api-approved.kubernetes.io": "https://github.com/kubernetes/test-infra/pull/8669"
spec:
group: prow.k8s.io
version: v1
names:
kind: ProwJob
singular: prowjob
plural: prowjobs
scope: Namespaced
validation:
openAPIV3Schema:
properties:
spec:
versions:
- name: v1
served: true
storage: true
schema:
openAPIV3Schema:
type: object
properties:
max_concurrency:
type: integer
minimum: 0
type:
type: string
enum:
- "presubmit"
- "postsubmit"
- "periodic"
- "batch"
status:
properties:
state:
type: string
enum:
- "triggered"
- "pending"
- "success"
- "failure"
- "aborted"
- "error"
anyOf:
- not:
spec:
type: object
x-kubernetes-preserve-unknown-fields: true
properties:
max_concurrency:
type: integer
minimum: 0
type:
type: string
enum:
- "presubmit"
- "postsubmit"
- "periodic"
- "batch"
status:
type: object
x-kubernetes-preserve-unknown-fields: true
properties:
state:
type: string
enum:
- "success"
- "failure"
- "error"
- required:
- completionTime
additionalPrinterColumns:
- name: Job
type: string
description: The name of the job being run.
JSONPath: .spec.job
- name: BuildId
type: string
description: The ID of the job being run.
JSONPath: .status.build_id
- name: Type
type: string
description: The type of job being run.
JSONPath: .spec.type
- name: Org
type: string
description: The org for which the job is running.
JSONPath: .spec.refs.org
- name: Repo
type: string
description: The repo for which the job is running.
JSONPath: .spec.refs.repo
- name: Pulls
type: string
description: The pulls for which the job is running.
JSONPath: ".spec.refs.pulls[*].number"
- name: StartTime
type: date
description: When the job started running.
JSONPath: .status.startTime
- name: CompletionTime
type: date
description: When the job finished running.
JSONPath: .status.completionTime
- name: State
description: The state of the job.
type: string
JSONPath: .status.state
- "triggered"
- "pending"
- "success"
- "failure"
- "aborted"
- "error"
anyOf:
- not:
properties:
state:
enum:
- "success"
- "failure"
- "error"
- required:
- completionTime
additionalPrinterColumns:
- name: Job
type: string
description: The name of the job being run.
jsonPath: .spec.job
- name: BuildId
type: string
description: The ID of the job being run.
jsonPath: .status.build_id
- name: Type
type: string
description: The type of job being run.
jsonPath: .spec.type
- name: Org
type: string
description: The org for which the job is running.
jsonPath: .spec.refs.org
- name: Repo
type: string
description: The repo for which the job is running.
jsonPath: .spec.refs.repo
- name: Pulls
type: string
description: The pulls for which the job is running.
jsonPath: ".spec.refs.pulls[*].number"
- name: StartTime
type: date
description: When the job started running.
jsonPath: .status.startTime
- name: CompletionTime
type: date
description: When the job finished running.
jsonPath: .status.completionTime
- name: State
description: The state of the job.
type: string
jsonPath: .status.state
5 changes: 2 additions & 3 deletions prow/templates/branchprotector-cronjob.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
apiVersion: batch/v1beta1
apiVersion: batch/v1
kind: CronJob
metadata:
name: branchprotector
Expand All @@ -25,8 +25,7 @@ spec:
- --github-endpoint=http://ghproxy
- --github-endpoint=https://api.github.com
- --github-token-path=/etc/github/oauth
- --confirm=true
- --github-endpoint=http://ghproxy
- --confirm
volumeMounts:
- name: oauth
mountPath: /etc/github
Expand Down
1 change: 0 additions & 1 deletion prow/templates/config-configmap.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
---
apiVersion: v1
data:
kind: ConfigMap
metadata:
name: config
Expand Down
4 changes: 2 additions & 2 deletions prow/templates/crier-rbac.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ rules:
- "list"
---
kind: RoleBinding
apiVersion: rbac.authorization.k8s.io/v1beta1
apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: crier-namespaced
roleRef:
Expand All @@ -46,7 +46,7 @@ subjects:
name: "crier"
---
kind: RoleBinding
apiVersion: rbac.authorization.k8s.io/v1beta1
apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: crier-namespaced
namespace: {{ .Values.podNamespace }}
Expand Down
21 changes: 0 additions & 21 deletions prow/templates/deck-ingress.yaml

This file was deleted.

8 changes: 4 additions & 4 deletions prow/templates/deck-rbac.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ metadata:
name: "deck"
---
kind: Role
apiVersion: rbac.authorization.k8s.io/v1beta1
apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: "deck"
rules:
Expand All @@ -20,7 +20,7 @@ rules:
- create
---
kind: RoleBinding
apiVersion: rbac.authorization.k8s.io/v1beta1
apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: "deck"
roleRef:
Expand All @@ -32,7 +32,7 @@ subjects:
name: "deck"
---
kind: Role
apiVersion: rbac.authorization.k8s.io/v1beta1
apiVersion: rbac.authorization.k8s.io/v1
metadata:
namespace: {{ .Values.podNamespace }}
name: "deck"
Expand All @@ -45,7 +45,7 @@ rules:
- get
---
kind: RoleBinding
apiVersion: rbac.authorization.k8s.io/v1beta1
apiVersion: rbac.authorization.k8s.io/v1
metadata:
namespace: {{ .Values.podNamespace }}
name: "deck"
Expand Down
21 changes: 0 additions & 21 deletions prow/templates/hook-ingress.yaml

This file was deleted.

4 changes: 2 additions & 2 deletions prow/templates/hook-rbac.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ metadata:
name: "hook"
---
kind: Role
apiVersion: rbac.authorization.k8s.io/v1beta1
apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: "hook"
rules:
Expand All @@ -27,7 +27,7 @@ rules:
- update
---
kind: RoleBinding
apiVersion: rbac.authorization.k8s.io/v1beta1
apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: "hook"
roleRef:
Expand Down
5 changes: 3 additions & 2 deletions prow/templates/horologium-rbac.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ metadata:
name: "horologium"
---
kind: Role
apiVersion: rbac.authorization.k8s.io/v1beta1
apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: "horologium"
rules:
Expand All @@ -15,9 +15,10 @@ rules:
verbs:
- create
- list
- watch
---
kind: RoleBinding
apiVersion: rbac.authorization.k8s.io/v1beta1
apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: "horologium"
roleRef:
Expand Down
58 changes: 58 additions & 0 deletions prow/templates/ing_ingress.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
{{- with .Values.ingress.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
name: deck
spec:
ingressClassName: {{ .Values.ingress.ingressClass }}
rules:
- host: {{ quote .Values.ingress.host }}
http:
paths:
- path: /
pathType: ImplementationSpecific
backend:
service:
name: deck
port:
number: 80
- path: /metrics
pathType: ImplementationSpecific
backend:
service:
name: pushgateway-external
port:
number: 80
tls:
- hosts:
- {{ quote .Values.ingress.host }}
secretName: {{ quote .Values.ingress.host }}
---
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
{{- with .Values.ingress.hookAnnotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
name: hook
spec:
ingressClassName: {{ .Values.ingress.ingressClass }}
rules:
- host: {{ quote .Values.ingress.host }}
http:
paths:
- path: /hook
pathType: ImplementationSpecific
backend:
service:
name: hook
port:
number: 8888
tls:
- hosts:
- {{ quote .Values.ingress.host }}
secretName: {{ quote .Values.ingress.host }}
Loading

0 comments on commit ff24643

Please sign in to comment.