Add unixtime option #2

Merged
bortzmeyer merged 1 commits from faust/check_expire:add-output into master 2021-07-07 11:00:42 +02:00
Contributor

Add an option to return the expiration date in unixtime (time since
epoch).

./check_expire -H domain -u

It's particularly useful for alerting or monitoring systems that do
their own calculation based on the metric they receive (and not based on
exit codes).

For instance you can use the following in zabbix 5.4:

  • item: check_expire["-H","{HOST.CONN}","-u"]
  • trigger: last(/check_expire["-H","{HOST.CONN}","-u"])-now()<2592000

Where 2592000 is 30 days in seconds.

Also, remove some trailing whitespaces.

Add an option to return the expiration date in unixtime (time since epoch). ./check_expire -H domain -u It's particularly useful for alerting or monitoring systems that do their own calculation based on the metric they receive (and not based on exit codes). For instance you can use the following in zabbix 5.4: - item: check_expire["-H","{HOST.CONN}","-u"] - trigger: last(/check_expire["-H","{HOST.CONN}","-u"])-now()<2592000 Where 2592000 is 30 days in seconds. Also, remove some trailing whitespaces.
faust added 1 commit 2021-07-07 10:16:05 +02:00
342f89844b
Add unixtime option
Add an option to return the expiration date in unixtime (time since
epoch).

  ./check_expire -H domain -u

It's particularly useful for alerting or monitoring systems that do
their own calculation based on the metric they receive (and not based on
exit codes).

For instance you can use the following in zabbix 5.4:
- item: check_expire["-H","{HOST.CONN}","-u"]
- trigger: last(/check_expire["-H","{HOST.CONN}","-u"])-now()<2592000

Where 2592000 is 30 days in seconds.
bortzmeyer merged commit 86436ef1f0 into master 2021-07-07 11:00:42 +02:00
Sign in to join this conversation.
No reviewers
No Label
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: bortzmeyer/check_expire#2
No description provided.