Guest User

Untitled

a guest
Jun 25th, 2018
73
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.86 KB | None | 0 0
  1. define command{
  2. command_name check_temp_example
  3. command_line /var/lib/shinken/libexec/check_temp_example.py -a 5
  4. }
  5.  
  6. define service{
  7. host_name localhost
  8. service_description check_temp_example
  9. check_command check_temp_example
  10. max_check_attempts 5
  11. check_interval 1
  12. retry_interval 1
  13. check_period 24x7
  14. notification_interval 30
  15. notification_period 24x7
  16. notification_options w,c,r
  17. contact_groups admins
  18. icon_set server
  19. }
  20.  
  21. #!/usr/bin/env python
  22. # -*- coding: utf-8 -*-
  23. import sys
  24. import argparse
  25. from random import randint
  26.  
  27. parser = argparse.ArgumentParser()
  28. parser.add_argument("-a", help="The state of service", type=int)
  29. args = parser.parse_args()
  30. state = args.a
  31. print state
Add Comment
Please, Sign In to add comment