# How to configure prometheus ssl host with metricbeat?

**URL:** <https://discuss.elastic.co/t/how-to-configure-prometheus-ssl-host-with-metricbeat/345997>\
**Category:** Beats\
**Tags:** metricbeat\
**Created:** [October 30, 2023, 2:05am UTC](https://discuss.elastic.co/t/how-to-configure-prometheus-ssl-host-with-metricbeat/345997 "2023-10-30T02:05:07Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![pooh97](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/pooh97/32/127024_2.png) [@pooh97](https://discuss.elastic.co/u/pooh97)\
**Post date:** [October 30, 2023, 2:05am UTC](https://discuss.elastic.co/t/how-to-configure-prometheus-ssl-host-with-metricbeat/345997/1 "2023-10-30T02:05:07Z")

</div>

This is my first time on elasticsearch.

I have to get metrics from prometheus hosts with ssl.

I'll describe my develop environment in advance.

I'm using metricbeat 8.8.2 on A Server.

But I want to scrap Prometheus federate metrics on B Server.

Unfortunately, I have to get my prometheus federate metrics from not localhost ,but remote server.

Prometheus service provided below url :  
`ex)"https://prometheus-k8s-federate.aaa.com"`

But when I tested that URL using curl, I didn't work.

`ex) "https://prometheus-k8s-federate.aaa.com/federate"`

Above URL did working with JWT Token using POSTMAN APP.

How to configure metricbeat configure file for prometheus ssl host?

* * *

```auto
modules.d/prometheus.yml 

- module:prometheus
  enabled: true 
  hosts: "https://prometheus-k8s-federate.aaa.com" 
  metric_path : "/federate" 
  ssl.certificate_authorities: ["/aaa/my-aaa.pem"]
  username: "my-username"
  password: "mypassword"

```

* * *

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [November 27, 2023, 4:05am UTC](https://discuss.elastic.co/t/how-to-configure-prometheus-ssl-host-with-metricbeat/345997/2 "2023-11-27T04:05:14Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
