summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJan Doskočil <jan.doskocil@nic.cz>2024-11-26 12:25:33 +0100
committerJan Doskočil <jan.doskocil@nic.cz>2024-11-26 13:45:24 +0100
commit672967638cfc31ea90305ccf7298317495a02689 (patch)
tree01a267948e639afd7006717b6389104a88ffc50f
parentMerge branch 'ngtcp_upgrade' into 'master' (diff)
downloadknot-672967638cfc31ea90305ccf7298317495a02689.tar.xz
knot-672967638cfc31ea90305ccf7298317495a02689.zip
knot-exporter: no zone timers by default
-rwxr-xr-xpython/knot_exporter/knot_exporter/knot_exporter.py20
1 files changed, 14 insertions, 6 deletions
diff --git a/python/knot_exporter/knot_exporter/knot_exporter.py b/python/knot_exporter/knot_exporter/knot_exporter.py
index 8135294b4..7d6fc3791 100755
--- a/python/knot_exporter/knot_exporter/knot_exporter.py
+++ b/python/knot_exporter/knot_exporter/knot_exporter.py
@@ -216,15 +216,23 @@ def main():
)
parser.add_argument(
- "--no-zone-timers",
+ "--no-zone-serial",
action='store_false',
- help="disable collection of zone timer settings"
+ help="disable collection of zone serial"
)
parser.add_argument(
- "--no-zone-serial",
- action='store_false',
- help="disable collection of zone serial"
+ "--zone-timers",
+ action='store_true',
+ default=False,
+ help="enable collection of zone SOA timer values"
+ )
+
+ parser.add_argument(
+ "--no-zone-timers",
+ action='store_const',
+ help="supported for compatibility reasons; no effect",
+ # deprecated=True # in python >=3.13
)
args = parser.parse_args()
@@ -237,7 +245,7 @@ def main():
args.no_global_stats,
args.no_zone_stats,
args.no_zone_status,
- args.no_zone_timers,
+ args.zone_timers,
args.no_zone_serial,
))