Skip to content

Commit 84d09a6

Browse files
committed
A few fixes for prometheus
1 parent 12e5597 commit 84d09a6

File tree

3 files changed

+13
-1
lines changed

3 files changed

+13
-1
lines changed

internal/catalog.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ func init() {
2020
register(&BuilderHub{})
2121
register(&BuilderHubPostgres{})
2222
register(&BuilderHubMockProxy{})
23+
register(&nullService{})
2324
}
2425

2526
func FindComponent(name string) ServiceGen {

internal/components.go

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -571,3 +571,13 @@ func (p *OpReth) Watchdog(out io.Writer, instance *instance, ctx context.Context
571571
rethURL := fmt.Sprintf("http://localhost:%d", instance.service.MustGetPort("http").HostPort)
572572
return watchChainHead(out, rethURL, 2*time.Second)
573573
}
574+
575+
type nullService struct {
576+
}
577+
578+
func (n *nullService) Run(service *Service, ctx *ExContext) {
579+
}
580+
581+
func (n *nullService) Name() string {
582+
return "null"
583+
}

internal/local_runner.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -950,7 +950,8 @@ func CreatePrometheusServices(manifest *Manifest, out *output) error {
950950
WithTag("latest").
951951
WithArgs("--config.file", "/data/prometheus.yaml").
952952
WithPort("metrics", 9090, "tcp").
953-
WithArtifact("/data/prometheus.yml", "prometheus.yaml")
953+
WithArtifact("/data/prometheus.yaml", "prometheus.yaml")
954+
srv.ComponentName = "null" // For now, later on we can create a Prometheus component
954955
manifest.services = append(manifest.services, srv)
955956

956957
return nil

0 commit comments

Comments
 (0)