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

Harbor metrics exporter #1798

Open
tnubeo1111 opened this issue Jul 18, 2024 · 4 comments
Open

Harbor metrics exporter #1798

tnubeo1111 opened this issue Jul 18, 2024 · 4 comments
Assignees
Labels

Comments

@tnubeo1111
Copy link

Hello team,

Currently I am setting up harbor version 2.11.0 using helm but now I want to enable harbor metrics and transfer metrics to another prometheus server, what should I do? I followed the docs but it still doesn't work

Hope the team can help.

@Kajot-dev
Copy link
Contributor

You need to provide more info. How did you deploy it, where, what did you try?

@tnubeo1111
Copy link
Author

Thank you for responding.

Currently I have installed and configured Harbor (v2.11.0) using helm in a k8s cluster that specializes in providing services on it.

Next there is a k8s cluster that specializes in monitoring.

Then I went to the harbor's values ​​file to configure metrics.enable=true to configure metrics. But I see that it is currently configuring port 8001 and the path is /metrics, which means it is active in pods. If I want to see the harbor's metrics, I have to build an additional prometheus in the harbor's k8s cluster to see it.

But now that I have built a prometheus in a completely different cluster from the harbor, can I ask if there is a way for a prometheus in another cluster to get the metrics of the harbor?

I just have an idea to create a new service about NodePort and then add the labels of the exporter app.kubernetes.io/component: exporter, I don't know if that's possible.

@zyyw zyyw transferred this issue from goharbor/harbor Jul 22, 2024
@Kajot-dev
Copy link
Contributor

You would need to expose it somehow. Either via separate Ingress (since Ingress only listens on http/s) or via NodePort/Loadbalancer service.

Although sending metric between the clusters does not make much sense to me, escpecially from the security standpoint. It would be much better to for example use Prometheus Operator which provides neat CRD like ServiceMonitor, PrometheusRule just for that + AlertManager for notifications

Copy link

This issue is being marked stale due to a period of inactivity. If this issue is still relevant, please comment or remove the stale label. Otherwise, this issue will close in 30 days.

@github-actions github-actions bot added the Stale label Sep 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants