Skip to content
This repository has been archived by the owner on Mar 6, 2023. It is now read-only.

Add clarification surrounding when the .rules file is copied & where it goes #156

Merged
merged 2 commits into from
Oct 29, 2018
Merged

Conversation

wbh1
Copy link
Contributor

@wbh1 wbh1 commented Oct 25, 2018

This PR adds a debug statement to warn users that their rules configuration won't be copied if they didn't provide a prometheus_alertmanager_config value but DID provide a prometheus_alert_rules value in defaults/main.yml

Also updates the README to reflect that the .rules file gets saved to ansible_managed.rules rather than basic.rules

Fixes #148

@paulfantom
Copy link
Member

It might be better to move this to preflight.yml and fail the execution.

@wbh1
Copy link
Contributor Author

wbh1 commented Oct 26, 2018

@paulfantom Good call. I've updated it accordingly. Let me know what you think.

@paulfantom
Copy link
Member

There is one more thing. By default this role creates some alerting rules but it doesn't set any alertmanager config, so this PR in current form will break default test scenario. We have two choices here:

  1. comment-out default value of prometheus_alert_rules
  2. revert to debug option and only notify user about lacking alertmanager section

I have no strong opinions on either, but I think that your initial concept is a better way.

@wbh1
Copy link
Contributor Author

wbh1 commented Oct 29, 2018

@paulfantom -- I've reverted back to using debug instead of fail :)

The build failed again, but the output seems to indicate that it's unrelated to my changes. Let me know if there's anything else that needs to be altered.

@paulfantom paulfantom merged commit d9ae691 into cloudalchemy:master Oct 29, 2018
@wbh1 wbh1 deleted the alertingrules branch October 29, 2018 22:47
slomo pushed a commit to slomo/ansible-prometheus that referenced this pull request Dec 12, 2018
…it goes (cloudalchemy#156)

[patch]

* Update README with correct location of the .rules file

* Add clarification surrounding when the .rules file is copied
@lock
Copy link

lock bot commented Mar 24, 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 24, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants