summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorarienv <arien@vijn.net>2018-07-07 11:10:12 +0200
committerytti <saku@ytti.fi>2018-07-07 12:10:12 +0300
commit55036037d9dac7b142813da8c3ff1370c31acbea (patch)
treecc4fde9143f078e23f122df9eb8bb7629a9b2e06
parentedb784636de189707dedcd01857ecacf7b2a88fd (diff)
Add support for ECI Telecom Apollo platform (#1437)
PR #1437
-rw-r--r--CHANGELOG.md2
-rw-r--r--docs/Supported-OS-Types.md2
-rw-r--r--lib/oxidized/model/eciapollo.rb34
3 files changed, 38 insertions, 0 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 3500c0e..f974735 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -7,6 +7,8 @@
* BUGFIX: model edgecos, ciscosmb
* MISC: bump Dockerfile phusion/baseimage:0.10.0 -> 0.10.1
* FEATURE: add viptela model (@bobthebutcher)
+* FEATURE: add ECI Telecom Appolo platform bij arien.vijn@linklight.nl
+
## 0.24.0
diff --git a/docs/Supported-OS-Types.md b/docs/Supported-OS-Types.md
index 59775ae..5cabd7b 100644
--- a/docs/Supported-OS-Types.md
+++ b/docs/Supported-OS-Types.md
@@ -76,6 +76,8 @@
* [AOSW](/lib/oxidized/model/aosw.rb)
* D-Link
* [D-Link](/lib/oxidized/model/dlink.rb)
+* ECI Telecom
+ * [ECIapollo](/lib/oxidized/model/eciapollo.rb)
* EdgeCore
* [ES3528M](/lib/oxidized/model/edgecos.rb)
* Ericsson/Redback
diff --git a/lib/oxidized/model/eciapollo.rb b/lib/oxidized/model/eciapollo.rb
new file mode 100644
index 0000000..ad15360
--- /dev/null
+++ b/lib/oxidized/model/eciapollo.rb
@@ -0,0 +1,34 @@
+# ECI Telecom Apollo
+# Tested on OPT9608 systems via SSH and telnet
+
+class ECIapollo < Oxidized::Model
+ prompt /^([\w.@()-]+[#>]\s?)$/
+ comment '# '
+
+ cmd :all do |cfg|
+ cfg.each_line.to_a[1..-2].join
+ end
+
+ cmd :secret do |cfg|
+ cfg.gsub!(/community (\S+) {/, 'community <hidden> {')
+ cfg.gsub!(/ "\$\d\$\S+; ## SECRET-DATA/, ' <secret removed>;')
+ cfg
+ end
+
+ cfg :telnet do
+ username(/^login:/)
+ password(/^Password:/)
+ end
+
+ cfg :telnet, :ssh do
+ post_login 'set cli screen-length 0'
+ post_login 'set cli screen-width 0'
+ pre_logout 'exit'
+ end
+
+ cmd('show version') { |cfg| comment cfg }
+ cmd('show system licenses') { |cfg| comment cfg }
+ cmd('show configuration') { |cfg| comment cfg }
+ cmd('show configuration | display-set') { |cfg| cfg }
+ cmd('show chassis inventory') { |cfg| comment cfg }
+end