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

Support mute_time_intervals for Alertmanager #552

Closed
wants to merge 3 commits into from

Conversation

djordjeparovic
Copy link

Pull Request (PR) description

Support mute_time_intervals for Alertmanager config

This Pull Request (PR) fixes the following issues

If user defines something like:

prometheus::alertmanager::mute_time_intervals:
  - name: business_hours
    time_intervals:
      - weekdays: [ 'monday','tuesday','friday' ]
        times:
          - start_time: '16:00'
            end_time:   '23:59'
          - start_time: '00:00'
            end_time:   '07:00'

it won't be picked up, and therefore create a configuration error on other places "missing definition for business_hours".

@bastelfreak bastelfreak added the enhancement New feature or request label May 28, 2021
@@ -107,6 +107,7 @@
Array $templates,
String[1] $user,
String[1] $version,
Array $mute_time_intervals,
Copy link
Member

Choose a reason for hiding this comment

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

can you please add some unit tests for the change, add puppet-strings documentation at the top of the file and enforce the datatype for the array elements?

@bastelfreak
Copy link
Member

@djordjeparovic can you please rebase against our latest master branch, take a look at the failing tests and and your example as a unit test?

@treydock
Copy link

@bastelfreak This can be closed, was picked up in #563 with @djordjeparovic set as Co-Author.

@bastelfreak bastelfreak added skip-changelog and removed enhancement New feature or request tests-fail labels Jun 25, 2021
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