Skip to content
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

Ensure unique names for ClusterRoles in e2e tests #2625

Merged
merged 1 commit into from
Feb 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ automountServiceAccountToken: true
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
name: ta
name: create-sm-prometheus
rules:
- apiGroups: [""]
resources:
Expand Down Expand Up @@ -60,7 +60,7 @@ rules:
apiVersion: kuttl.dev/v1beta1
kind: TestStep
commands:
- command: kubectl create clusterrolebinding simplest-targetallocator-create-sm-prometheus --clusterrole=ta --serviceaccount=create-sm-prometheus:ta
- command: kubectl create clusterrolebinding simplest-targetallocator-create-sm-prometheus --clusterrole=create-sm-prometheus --serviceaccount=create-sm-prometheus:ta
---
apiVersion: opentelemetry.io/v1alpha1
kind: OpenTelemetryCollector
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ automountServiceAccountToken: true
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
name: pod-view
name: promreceiver-allocatorconfig
rules:
- apiGroups: [""]
resources: [ "pods", "namespaces" ]
Expand All @@ -16,7 +16,7 @@ rules:
apiVersion: kuttl.dev/v1beta1
kind: TestStep
commands:
- command: kubectl -n $NAMESPACE create clusterrolebinding default-view-$NAMESPACE --clusterrole=pod-view --serviceaccount=$NAMESPACE:ta
- command: kubectl -n $NAMESPACE create clusterrolebinding default-view-$NAMESPACE --clusterrole=promreceiver-allocatorconfig --serviceaccount=$NAMESPACE:ta
---
apiVersion: opentelemetry.io/v1alpha1
kind: OpenTelemetryCollector
Expand Down
4 changes: 2 additions & 2 deletions tests/e2e/smoke-targetallocator/00-install.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ automountServiceAccountToken: true
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
name: pod-view
name: smoke-targetallocator
rules:
- apiGroups: [""]
resources: [ "pods", "namespaces" ]
Expand All @@ -16,7 +16,7 @@ rules:
apiVersion: kuttl.dev/v1beta1
kind: TestStep
commands:
- command: kubectl -n $NAMESPACE create clusterrolebinding default-view-$NAMESPACE --clusterrole=pod-view --serviceaccount=$NAMESPACE:ta
- command: kubectl -n $NAMESPACE create clusterrolebinding default-view-$NAMESPACE --clusterrole=smoke-targetallocator --serviceaccount=$NAMESPACE:ta
---
apiVersion: opentelemetry.io/v1alpha1
kind: OpenTelemetryCollector
Expand Down
Loading