-
Notifications
You must be signed in to change notification settings - Fork 99
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
Feat/remote file #144
Feat/remote file #144
Conversation
Looks nice |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for this PR and sorry for taking so long to review it!
I have a few comments
- I don't think this should export
ssl_file_cert_*
metrics. We should just read the certificates out of the response body and export the regularssl_cert_*
metrics. We don't need the intermediate step where we write them to disk. - This also exports metrics from the TLS connection because it reuses the tls config used in the https prober:
Line 30 in 42d1d4f
return collectConnectionStateMetrics(state, registry) - Can you please improve the tests so that they actually verify the exported metrics?
Hi :) no worries I'm glad the project is still alive. I made the changes requested, at least I hope it matches your expectations. I honestly can't remember why I thought it was a good idea to download the file 😅 |
LGTM |
@ribbybibby can you please review if this PR now is okay? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changes suggested/requested in comments.
You can fetch remote content with a lot of different protocols, so I think it's worth being specific here. As part of this change I've fixed up some of the logic in the code. I've also created a separate `http_file` block in the module config.
Thank you for the contribution @jaroug. I've made some of my suggested changes and fixed some other things up and now I think this is good to merge. |
@ribbybibby can we get 2.5.0 released with this feature please? 🙏 |
@ribbybibby kind reminder - this feature not get into 2.4.3 release, as it was been released before merging this branch. |
@jaroug btw, I found out that I get managed to create alert for
|
Add support for probing a remote PEM file over http/https
This is a corner case to be able to monitor BIMI related certificates