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

digitalocean service discovery #4166

Closed
caarlos0 opened this Issue May 16, 2018 · 9 comments

Comments

Projects
None yet
3 participants
@caarlos0
Copy link

caarlos0 commented May 16, 2018

Proposal

Use case. Why is this important?

I want to use prometheus on DigitalOcean. My previous experience was on aws, using ec2_sd and all that.

I noticed, though, that there isn't a digitalocean_sd or something like that for digitalocean.

I could in theory use SD from files, etcd or whatever... but I think it would be useful for more people.

Is that from the interest of you guys? If it is, I can work on a PR.

Thanks!

@brian-brazil

This comment has been minimized.

Copy link
Member

brian-brazil commented May 16, 2018

Per https://github.com/prometheus/prometheus/tree/master/discovery#service-discovery we are not currently accepting new SD mechanisms, so would recommend that you use file_sd.

@krasi-georgiev

This comment has been minimized.

Copy link
Member

krasi-georgiev commented May 16, 2018

maybe we should update this to say

There is currently a moratorium on new service discovery mechanisms being added to Prometheus due to a lack of developer capacity for long term support and maintenance. In the meantime file_sd remains available.`

@caarlos0

This comment has been minimized.

Copy link
Author

caarlos0 commented May 16, 2018

oh, ok, got it.

If I compromise to maintain it, still not a thing you want to do?

about file_sd, the right way to inform the labels for each target is something like:

[
  {
    "targets": [ "1.2.3.4"],
    "labels": {
      "name": "foo"
    }
  },
  {
    "targets": [ "1.2.3.5"],
    "labels": {
      "name": "bar"
    }
  }
]

or is there a better way?

@krasi-georgiev

This comment has been minimized.

Copy link
Member

krasi-georgiev commented May 16, 2018

@caarlos0 here is a WIP PR with a very good example how to implement a custom SD that generates a json in the file_sd format.

@krasi-georgiev

This comment has been minimized.

Copy link
Member

krasi-georgiev commented May 16, 2018

btw a while ago I started a discussion about file_sd vs http_sd so if file_sd doesn't solve your use case you might give some feedback in the discussion.

@brian-brazil

This comment has been minimized.

Copy link
Member

brian-brazil commented May 16, 2018

If I compromise to maintain it, still not a thing you want to do?

Part of the reason the moratorium is all the previous sd creators who said the same thing, and did not follow through.

@caarlos0

This comment has been minimized.

Copy link
Author

caarlos0 commented May 16, 2018

Part of the reason the moratorium is all the previous sd creators who said the same thing, and did not follow through.

hm, OK, I can understand that. As much as I want to say I'll not be one of those, you have no reason to believe me, so it doesn't matter heh

Anyway, thanks for the replies, will try to make an external thing that generates the file in the right format, so other people may still use it anyway :)

Oh, and thanks for this great tool! Prometheus is awesome! 🤘

Cheers!

@caarlos0 caarlos0 closed this May 16, 2018

@caarlos0

This comment has been minimized.

Copy link
Author

caarlos0 commented May 18, 2018

In case anyone else needs this -> https://github.com/TOTVS/prometheus-digitalocean-sd

@lock

This comment has been minimized.

Copy link

lock bot commented Mar 22, 2019

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot locked and limited conversation to collaborators Mar 22, 2019

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
You can’t perform that action at this time.