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

Allow Prometheus to run GitHub Actions in e2e tests #613

Merged
merged 1 commit into from
Oct 8, 2023
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
4 changes: 2 additions & 2 deletions cmd/operator/deploy/operator/10-collector.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,8 @@ spec:
args:
- --config-file=/prometheus/config/config.yaml
- --config-file-output=/prometheus/config_out/config.yaml
- --reload-url=http://localhost:19090/-/reload
- --ready-url=http://localhost:19090/-/ready
- --reload-url=http://127.0.0.1:19090/-/reload
- --ready-url=http://127.0.0.1:19090/-/ready
- --listen-address=:19091
ports:
- name: cfg-rel-metrics
Expand Down
4 changes: 2 additions & 2 deletions cmd/operator/deploy/operator/11-rule-evaluator.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,8 @@ spec:
- --config-file-output=/prometheus/config_out/config.yaml
- --watched-dir=/etc/rules
- --watched-dir=/etc/secrets
- --reload-url=http://localhost:19092/-/reload
- --ready-url=http://localhost:19092/-/ready
- --reload-url=http://127.0.0.1:19092/-/reload
- --ready-url=http://127.0.0.1:19092/-/ready
- --listen-address=:19093
ports:
- name: cfg-rel-metrics
Expand Down
4 changes: 2 additions & 2 deletions cmd/operator/deploy/operator/12-alertmanager.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -101,8 +101,8 @@ spec:
args:
- --config-file=/alertmanager/config.yaml
- --config-file-output=/alertmanager/config_out/config.yaml
- --reload-url=http://localhost:9093/-/reload
- --ready-url=http://localhost:9093/-/ready
- --reload-url=http://127.0.0.1:9093/-/reload
- --ready-url=http://127.0.0.1:9093/-/ready
- --listen-address=:19091
ports:
- name: cfg-rel-metrics
Expand Down
4 changes: 2 additions & 2 deletions cmd/operator/deploy/rule-evaluator/01-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@ spec:
- --config-file=/prometheus/config/config.yaml
- --config-file-output=/prometheus/config_out/config.yaml
- --watched-dir=/etc/rules
- --reload-url=http://localhost:9092/-/reload
- --ready-url=http://localhost:9092/-/ready
- --reload-url=http://127.0.0.1:9092/-/reload
- --ready-url=http://127.0.0.1:9092/-/ready
- --listen-address=:9093
ports:
- name: cfg-rel-metrics
Expand Down
9 changes: 9 additions & 0 deletions e2e/operator_context_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -360,6 +360,15 @@ func createCollectorResources(ctx context.Context, kubeClient client.Client, nam
}
collector := obj.(*appsv1.DaemonSet)
collector.Namespace = namespace
if skipGCM {
for i := range collector.Spec.Template.Spec.Containers {
container := &collector.Spec.Template.Spec.Containers[i]
if container.Name == "prometheus" {
container.Args = append(container.Args, "--export.debug.disable-auth")
break
}
}
}

if err = kubeClient.Create(ctx, collector); err != nil {
return fmt.Errorf("create collector DaemonSet: %w", err)
Expand Down
12 changes: 6 additions & 6 deletions manifests/operator.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -585,8 +585,8 @@ spec:
args:
- --config-file=/prometheus/config/config.yaml
- --config-file-output=/prometheus/config_out/config.yaml
- --reload-url=http://localhost:19090/-/reload
- --ready-url=http://localhost:19090/-/ready
- --reload-url=http://127.0.0.1:19090/-/reload
- --ready-url=http://127.0.0.1:19090/-/ready
- --listen-address=:19091
ports:
- name: cfg-rel-metrics
Expand Down Expand Up @@ -761,8 +761,8 @@ spec:
- --config-file-output=/prometheus/config_out/config.yaml
- --watched-dir=/etc/rules
- --watched-dir=/etc/secrets
- --reload-url=http://localhost:19092/-/reload
- --ready-url=http://localhost:19092/-/ready
- --reload-url=http://127.0.0.1:19092/-/reload
- --ready-url=http://127.0.0.1:19092/-/ready
- --listen-address=:19093
ports:
- name: cfg-rel-metrics
Expand Down Expand Up @@ -967,8 +967,8 @@ spec:
args:
- --config-file=/alertmanager/config.yaml
- --config-file-output=/alertmanager/config_out/config.yaml
- --reload-url=http://localhost:9093/-/reload
- --ready-url=http://localhost:9093/-/ready
- --reload-url=http://127.0.0.1:9093/-/reload
- --ready-url=http://127.0.0.1:9093/-/ready
- --listen-address=:19091
ports:
- name: cfg-rel-metrics
Expand Down
4 changes: 2 additions & 2 deletions manifests/rule-evaluator.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,8 @@ spec:
- --config-file=/prometheus/config/config.yaml
- --config-file-output=/prometheus/config_out/config.yaml
- --watched-dir=/etc/rules
- --reload-url=http://localhost:9092/-/reload
- --ready-url=http://localhost:9092/-/ready
- --reload-url=http://127.0.0.1:9092/-/reload
- --ready-url=http://127.0.0.1:9092/-/ready
- --listen-address=:9093
ports:
- name: cfg-rel-metrics
Expand Down