title: Prometheus - Scrape metrics endpoint over mTLS
body: <p>Small question regarding how to scrape a /metrics endpoint over HTTPS, mutual TLS, mutual SSL.</p>
  <p>Our Prometheus instance is deployed in a location A.</p>
  <p>We then have bunch of micro services deployed all over the places, but never same places as Prometheus.</p>
  <p>All micro services successfully expose a /metrics endpoint, ready for Prometheus to come and poll the data. We see the data in Prometheus format already.</p>
  <p>All micro services MUST expose the /metrics endpoint over HTTPS, mTLS, mutual TLS, two way SSL.</p>
  <p>The test in QA with all micro services exposing the /metrics endpoint over plain old simple HTTP only works perfectly fine. Prometheus is successfully polling all data with this configuration.</p>
  <pre><code>    scrape_configs:
        - job_name: 'some-job-name'
          metrics_path: /metrics
          static_configs:
            - targets:
              - some-host.com:8080
  </code></pre>
  <p>However, in Prod, the /metrics MUST be over HTTPS mTLS</p>
  <p>The goal of this question is not to create an argument if /metrics endpoints should be over HTTP or HTTPS. The question is really a technical question of how to make Prometheus able to query this /metrics endpoint over HTTPS, mTLS.</p>
  <p>What would be the configuration to allow Prometheus scraping those existing data over HTTPS, mTLS please?</p>
  <p>Thank you!</p>