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

fix: scrape config files path #377

Merged

Conversation

manzsolutions-lpr
Copy link
Contributor

@manzsolutions-lpr manzsolutions-lpr commented Jun 3, 2024

Unfortunately simply rebasing the original PR I missed that the paths in the actual role are wrong. I have now updated them and took the chance to also re-use the variable's value for the actual configuration not just the glob for copying.

//edit: Cannot reuse variable since it would lead to /etc/prometheus/prometheus/scrapes/....

@manzsolutions-lpr manzsolutions-lpr changed the title Fix scrape config files path Draft: Fix scrape config files path Jun 3, 2024
@manzsolutions-lpr manzsolutions-lpr marked this pull request as draft June 3, 2024 14:47
@manzsolutions-lpr manzsolutions-lpr force-pushed the fix-scrape-config-path branch from f91150b to e1d97f9 Compare June 3, 2024 14:50
@manzsolutions-lpr manzsolutions-lpr changed the title Draft: Fix scrape config files path Fix scrape config files path Jun 3, 2024
@manzsolutions-lpr manzsolutions-lpr marked this pull request as ready for review June 3, 2024 15:09
@manzsolutions-lpr
Copy link
Contributor Author

@gardar I would also add "notify"-Statements to all the file uploads to trigger a reload of Prometheus. May I add this in this PR?

@gardar gardar changed the title Fix scrape config files path fix: scrape config files path Jun 6, 2024
Copy link
Member

@gardar gardar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@gardar I would also add "notify"-Statements to all the file uploads to trigger a reload of Prometheus. May I add this in this PR?

Sure, go ahead.
Could you also please add tests to molecule molecule so that we can verify that it actually works as intended?

@github-actions github-actions bot added bugfix and removed bugfix labels Jun 6, 2024
@github-actions github-actions bot added bugfix and removed bugfix labels Jun 10, 2024
@github-actions github-actions bot added bugfix and removed bugfix labels Jun 10, 2024
@manzsolutions-lpr manzsolutions-lpr marked this pull request as draft June 10, 2024 12:07
@github-actions github-actions bot added bugfix and removed bugfix labels Jun 10, 2024
@github-actions github-actions bot added bugfix and removed bugfix labels Jun 10, 2024
Copy link
Contributor

@SuperQ SuperQ left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we should name this more explicitly the same to make it clear what it is.

Comment on lines 101 to 102
- prometheus/scrapes/*.yml
- prometheus/scrapes/*.json
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should probably be scrape_configs.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done. Please note that this implies a breaking change which requires manual clean-up by people who attempted to use this broken functionality.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you do the cleanup or add a warning if manual cleanup is required in the preflight?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just deleting the folder as a clean-up is risky since people may have added their own scrape files but since it’s broken it would not have had an effect either way. What would you rather have?

Impact of not cleaning it up (automatically or manually): There is an orphaned folder with unused configuration files probably confusing administrators.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I opted to remove the folder after all since it was never actually used but automatically created for every installation making it a hassle even for users who never attempted to use the feature to begin with.

@github-actions github-actions bot added bugfix and removed bugfix labels Oct 4, 2024
@github-actions github-actions bot added bugfix and removed bugfix labels Oct 4, 2024
Copy link
Contributor

github-actions bot commented Oct 4, 2024

Docs Build 📝

Thank you for contribution!✨

This PR has been merged and the docs are now incorporated into main:
https://prometheus-community.github.io/ansible/branch/main

@manzsolutions-lpr
Copy link
Contributor Author

@SuperQ I did rename it, do you have any other suggestions?

Not too familiar with the Github UI, do I have to mark somehow that the requested change was performed?

Copy link
Member

@gardar gardar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you mind rebasing this again? I just did some significant refactoring of the roles in #425

Signed-off-by: Leonhard Mayr <leonhard.mayr@manz.at>
Signed-off-by: Leonhard Mayr <leonhard.mayr@manz.at>
Signed-off-by: Leonhard Mayr <leonhard.mayr@manz.at>
Signed-off-by: Leonhard Mayr <leonhard.mayr@manz.at>
Signed-off-by: Leonhard Mayr <leonhard.mayr@manz.at>
@manzsolutions-lpr
Copy link
Contributor Author

Do you mind rebasing this again? I just did some significant refactoring of the roles in #425

While I hopefully solved these merge conflicts one last time I’m not comfortable to sink any more time into this PR. It has dragged on for more than four months now despite my best efforts to comply with requested changes and feedback in a timely manner due to reasons mostly outside of my control.

Thank you for your ongoing work on this project!

@gardar
Copy link
Member

gardar commented Oct 17, 2024

Do you mind rebasing this again? I just did some significant refactoring of the roles in #425

While I hopefully solved these merge conflicts one last time I’m not comfortable to sink any more time into this PR. It has dragged on for more than four months now despite my best efforts to comply with requested changes and feedback in a timely manner due to reasons mostly outside of my control.

Thank you for your ongoing work on this project!

LGTM!
Thanks for the patience, you caught us at a bad time working through some technical debt 😅

@gardar
Copy link
Member

gardar commented Oct 18, 2024

ping @SuperQ

@gardar
Copy link
Member

gardar commented Oct 25, 2024

All set on my end. @SuperQ Any final thoughts before we merge this?

Copy link
Contributor

@SuperQ SuperQ left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks!

@gardar gardar merged commit e2d8b74 into prometheus-community:main Oct 25, 2024
59 checks passed
@manzsolutions-lpr manzsolutions-lpr deleted the fix-scrape-config-path branch October 28, 2024 07:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants