Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

In this manual we will describe how to make a local copy of a built-in notification script. There are two ways:

Table of Contents

Quick and dirty way 

Info
  1. Copy the notification plugin to the local directory

    Code Block
    OMD[at]:~$ cp ~/lib/python3/cmk/cee/notification_plugins/servicenow.py ~/local/share/check_mk/notifications/


  2. make the script executable

    Code Block
    OMD[at]:~/local/share/check_mk/notifications$ chmod +x ~/local/share/check_mk/notifications/servicenow.py


  3. Inside the script, you need to change:
    1. The 3rd line to a name of your script. This name will be displayed in the Notification rules

      Code Block
      3 # Notification script name
      4 # Bulk: no


    2. at the end of the notification script, we need to add:

      Code Block
      if __name__ == "__main__":
          sys.exit(main())




...