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

GRPC server access to metrics from prometheus #567

Open
vseregin63 opened this issue Dec 17, 2024 · 1 comment
Open

GRPC server access to metrics from prometheus #567

vseregin63 opened this issue Dec 17, 2024 · 1 comment

Comments

@vseregin63
Copy link

Have a good day, @karimra !

We use TLS client-auth protection on GNMIC api interface. It helps us to hide sensitive data, available through this interface. But before TLS was enabled we also collected grpc server metrics from point http://hostname:7890/metrics on the same api port 7890.

api-server:
  tls:
    ca-file: /certs/rootCA.crt
    cert-file: /certs/api_server.pem
    key-file: /certs/api_server.key
    client-auth: "require"
  enable-metrics: true 

Now after TLS was enabled we can't collect this data by prometheus because it doesn't support TLS authentication by client certs (at least in our infra). Please tell us how we can disable TLS for this url only (http://hostname:7890/metrics), or may be we can add some hosts/nets to exception? If we cant do it now, can you please add it to project development plan?

Thnx

@karimra
Copy link
Collaborator

karimra commented Dec 30, 2024

TLS cannot be disabled per URL.

Prometheus supports TLS on the client side:

scrape_configs:
  - job_name: 'telemetry'
    scheme: https
    tls_config:
        ca_file: 'ca.crt'
        cert_file: 'client.crt'
        key_file: 'client.key'
    static_configs:
    - targets: ['router1:57400']

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants