Commit cf56d359 authored by Dmitry Lukhtionov's avatar Dmitry Lukhtionov
Browse files

Fix Raisecom.RCIOS pager

parent 6c95ac26
......@@ -3,7 +3,7 @@
# Vendor: Raisecom
# OS: RCIOS
# ----------------------------------------------------------------------
# Copyright (C) 2007-2017 The NOC Project
# Copyright (C) 2007-2018 The NOC Project
# See LICENSE for details
# ----------------------------------------------------------------------
......@@ -19,6 +19,9 @@ class Profile(BaseProfile):
pattern_prompt = r"^(?P<hostname>\S+)# "
command_exit = "exit"
pattern_syntax_error = r"% \".+\" (?:Unknown command.)"
pattern_more = [
(r"^--More-- \(\d+% of \d+ bytes\)", "r")
]
INTERFACE_TYPES = {
"3g": "tunnel",
......@@ -31,14 +34,6 @@ class Profile(BaseProfile):
"vl": "SVI",
}
def setup_script(self, script):
if script.parent is None:
s_password = script.credentials.get("super_password", "")
self.pattern_more = [
(r"^--More-- \(\d+% of \d+ bytes\)", "r"),
(r"^Enable: ", s_password + "\n")
]
@classmethod
def get_interface_type(cls, name):
return cls.INTERFACE_TYPES.get((name[:2]).lower())
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment