From 0d9582913f981c4503ccd9c266bfa901c2d9dc06 Mon Sep 17 00:00:00 2001
From: thl-cmk <thl-cmk@outlook.com>
Date: Tue, 10 Aug 2021 19:34:59 +0000
Subject: [PATCH] Delete checkpoint_powersupply

---
 checks/checkpoint_powersupply | 78 -----------------------------------
 1 file changed, 78 deletions(-)
 delete mode 100644 checks/checkpoint_powersupply

diff --git a/checks/checkpoint_powersupply b/checks/checkpoint_powersupply
deleted file mode 100644
index 2a1b651..0000000
--- a/checks/checkpoint_powersupply
+++ /dev/null
@@ -1,78 +0,0 @@
-#!/usr/bin/python
-# -*- encoding: utf-8; py-indent-offset: 4 -*-
-#
-#
-# License: GNU General Public License v2
-#
-# Author: thl-cmk[at]outlook[dot]com
-# URL   : https://thl-cmk.hopto.org
-# Date  : 2018-07-31
-#
-# Monitor status of Check Point appliance power supply
-#
-# 2020-06-08: changed snmp-scan function
-#
-# ToDo: remove VSX...
-#
-# sample snmpwalk (two  power supplys)
-#
-# CHECKPOINT-MIB::powerSupplyIndex.1.0 = INTEGER: 1
-# CHECKPOINT-MIB::powerSupplyIndex.2.0 = INTEGER: 2
-# CHECKPOINT-MIB::powerSupplyStatus.1.0 = STRING: Up
-# CHECKPOINT-MIB::powerSupplyStatus.2.0 = STRING: Up
-#
-#
-# .1.3.6.1.4.1.2620.1.6.7.9.1.1.1.1.0 = INTEGER: 1
-# .1.3.6.1.4.1.2620.1.6.7.9.1.1.1.2.0 = INTEGER: 2
-# .1.3.6.1.4.1.2620.1.6.7.9.1.1.2.1.0 = STRING: Up
-# .1.3.6.1.4.1.2620.1.6.7.9.1.1.2.2.0 = STRING: Up
-
-#
-#
-# sample info
-# two power supplys
-# [[u'1', u'Up'], [u'2', u'Up']]
-#
-#
-
-factory_settings['checkpoint_powersupply_defaults'] = {
-
-}
-
-
-def inventory_checkpoint_powersupply(info):
-    for powersupply in info:
-        psindex, psstatus = powersupply
-        if psindex.isdigit():
-            yield psindex, {}
-
-
-def check_checkpoint_powersupply(item, params, info):
-    for powersupply in info:
-        psindex, psstatus = powersupply
-        if psindex == item:
-            state = 0
-            infotext = ''
-            longoutput = ''
-            infotext = 'Status: %s' % psstatus
-            if psstatus.lower() != 'up':
-                status = 2
-
-            return state, infotext + longoutput
-
-
-check_info['checkpoint_powersupply'] = {
-    'check_function'          : check_checkpoint_powersupply,
-    'inventory_function'      : inventory_checkpoint_powersupply,
-    'default_levels_variable' : 'checkpoint_powersupply_defaults',
-    'service_description'     : 'Power supply %s',
-    'group'                   : 'cp_powersupply',
-    'snmp_scan_function': lambda oid: (oid('.1.3.6.1.2.1.1.2.0').startswith('.1.3.6.1.4.1.2620.1.6.123.1') or
-                                       oid('.1.3.6.1.2.1.1.2.0').startswith('.1.3.6.1.4.1.8072.3.2.10')) and
-                                      oid('.1.3.6.1.4.1.2620.1.6.1.0', '').lower().startswith('svn foundation'),
-    'snmp_info'               : ('.1.3.6.1.4.1.2620.1.6.7.9.1.1', [  # CHECKPOINT-MIB::powerSupplyEntry
-                                  '1',   # powerSupplyIndex
-                                  '2',   # powerSupplyStatus
-                                  ]),
-}
-
-- 
GitLab