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

feat(maintenance): Expose active_since and active_till fields #1180

Merged

Conversation

hairmare
Copy link
Contributor

SUMMARY

Allow specifying active_since and active_till when creating maintenances. This can be used instead of using minutes to create maintenances that start datetime.datetime.now().

ISSUE TYPE
  • Feature Pull Request
COMPONENT NAME

module zabbix_maintenance

ADDITIONAL INFORMATION

It works somewhat like this:

- name: 'RaBe Zabbix : Data Collection : Maintenance Period'
  vars:
    ansible_network_os: community.zabbix.zabbix
    ansible_connection: httpapi
    ansible_httpapi_port: 443
    ansible_httpapi_use_ssl: true
    ansible_zabbix_url_path: ''
    ansible_host: '{{ zabbix_api_server_url }}'
  community.zabbix.zabbix_maintenance:
    state: present
    name: Maintenance
    host_groups:
      - Maintenance
    active_since: "1970-01-01 01:00"
    active_till: "2038-01-01 13:12"

@hairmare hairmare force-pushed the feat/maintenance/add-date-fields branch 2 times, most recently from 094f6c4 to 856af47 Compare February 15, 2024 20:12
@hairmare hairmare force-pushed the feat/maintenance/add-date-fields branch from 856af47 to ae42975 Compare February 16, 2024 17:28
Copy link

codecov bot commented Feb 16, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (dc0116f) 79.56% compared to head (ae42975) 79.57%.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1180   +/-   ##
=======================================
  Coverage   79.56%   79.57%           
=======================================
  Files          35       35           
  Lines        4433     4435    +2     
  Branches     1166     1166           
=======================================
+ Hits         3527     3529    +2     
  Misses        535      535           
  Partials      371      371           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@hairmare hairmare marked this pull request as ready for review February 16, 2024 18:03
@pyrodie18 pyrodie18 merged commit facde86 into ansible-collections:main Feb 17, 2024
28 checks passed
@hairmare hairmare deleted the feat/maintenance/add-date-fields branch February 17, 2024 19:17
pyrodie18 pushed a commit to pyrodie18/community.zabbix that referenced this pull request Apr 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants