Skip to content

Commit

Permalink
chore: switch to kube-codegen
Browse files Browse the repository at this point in the history
Replace deprecated generate-groups.sh script with recommended
kube_codegen.sh script.
  • Loading branch information
bernot-dev committed Nov 16, 2023
1 parent 91fa0b3 commit 56474b8
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 12 deletions.
20 changes: 10 additions & 10 deletions examples/hpa/prometheus-adapter.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ metadata:
labels:
app.kubernetes.io/component: metrics-adapter
app.kubernetes.io/name: prometheus-adapter
app.kubernetes.io/version: 0.11.1
app.kubernetes.io/version: 0.8.0
name: prometheus-adapter
roleRef:
apiGroup: rbac.authorization.k8s.io
Expand All @@ -119,7 +119,7 @@ metadata:
labels:
app.kubernetes.io/component: metrics-adapter
app.kubernetes.io/name: prometheus-adapter
app.kubernetes.io/version: 0.11.1
app.kubernetes.io/version: 0.8.0
name: resource-metrics-server-resources
rules:
- apiGroups:
Expand All @@ -135,7 +135,7 @@ metadata:
labels:
app.kubernetes.io/component: metrics-adapter
app.kubernetes.io/name: prometheus-adapter
app.kubernetes.io/version: 0.11.1
app.kubernetes.io/version: 0.8.0
name: prometheus-adapter
rules:
- apiGroups:
Expand Down Expand Up @@ -178,7 +178,7 @@ metadata:
labels:
app.kubernetes.io/component: metrics-adapter
app.kubernetes.io/name: prometheus-adapter
app.kubernetes.io/version: 0.11.1
app.kubernetes.io/version: 0.8.0
name: adapter-config
namespace: monitoring
---
Expand All @@ -188,7 +188,7 @@ metadata:
labels:
app.kubernetes.io/component: metrics-adapter
app.kubernetes.io/name: prometheus-adapter
app.kubernetes.io/version: 0.11.1
app.kubernetes.io/version: 0.8.0
name: prometheus-adapter
namespace: monitoring
spec:
Expand All @@ -208,7 +208,7 @@ spec:
labels:
app.kubernetes.io/component: metrics-adapter
app.kubernetes.io/name: prometheus-adapter
app.kubernetes.io/version: 0.11.1
app.kubernetes.io/version: 0.8.0
spec:
automountServiceAccountToken: true
containers:
Expand Down Expand Up @@ -289,7 +289,7 @@ metadata:
labels:
app.kubernetes.io/component: metrics-adapter
app.kubernetes.io/name: prometheus-adapter
app.kubernetes.io/version: 0.11.1
app.kubernetes.io/version: 0.8.0
name: prometheus-adapter
namespace: monitoring
spec:
Expand Down Expand Up @@ -326,7 +326,7 @@ metadata:
labels:
app.kubernetes.io/component: metrics-adapter
app.kubernetes.io/name: prometheus-adapter
app.kubernetes.io/version: 0.11.1
app.kubernetes.io/version: 0.8.0
name: resource-metrics-auth-reader
namespace: kube-system
roleRef:
Expand All @@ -345,7 +345,7 @@ metadata:
labels:
app.kubernetes.io/component: metrics-adapter
app.kubernetes.io/name: prometheus-adapter
app.kubernetes.io/version: 0.11.1
app.kubernetes.io/version: 0.8.0
name: prometheus-adapter
namespace: monitoring
---
Expand All @@ -355,7 +355,7 @@ metadata:
labels:
app.kubernetes.io/component: metrics-adapter
app.kubernetes.io/name: prometheus-adapter
app.kubernetes.io/version: 0.11.1
app.kubernetes.io/version: 0.8.0
name: prometheus-adapter
namespace: monitoring
spec:
Expand Down
4 changes: 2 additions & 2 deletions hack/presubmit.sh
Original file line number Diff line number Diff line change
Expand Up @@ -54,13 +54,13 @@ update_codegen() {

# Invoke only for deepcopy first as it doesn't accept the pluralization flag
# of the second invocation.
bash "${CODEGEN_PKG}"/generate-groups.sh "deepcopy" \
bash "${CODEGEN_PKG}"/code-generator.sh "deepcopy" \
github.com/GoogleCloudPlatform/prometheus-engine/pkg/operator/generated github.com/GoogleCloudPlatform/prometheus-engine/pkg/operator/apis \
monitoring:v1 \
--go-header-file "${REPO_ROOT}"/hack/boilerplate.go.txt \
--output-base "${REPO_ROOT}"

bash "${CODEGEN_PKG}"/generate-groups.sh "client,informer,lister" \
bash "${CODEGEN_PKG}"/code-generator.sh "client,informer,lister" \
github.com/GoogleCloudPlatform/prometheus-engine/pkg/operator/generated github.com/GoogleCloudPlatform/prometheus-engine/pkg/operator/apis \
monitoring:v1 \
--go-header-file "${REPO_ROOT}"/hack/boilerplate.go.txt \
Expand Down

0 comments on commit 56474b8

Please sign in to comment.