summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--extra/oxidized.service5
-rw-r--r--lib/oxidized/model/ipos.rb8
-rw-r--r--lib/oxidized/model/xos.rb4
3 files changed, 14 insertions, 3 deletions
diff --git a/extra/oxidized.service b/extra/oxidized.service
index 35d7932..e474608 100644
--- a/extra/oxidized.service
+++ b/extra/oxidized.service
@@ -1,10 +1,11 @@
#For debian 8 put it in /lib/systemd/system/
+#For RHEL / CentOS 7 put it in /etc/systemd/system/
#and call it with systemctl start oxidized.service
[Unit]
Description=Oxidized - Network Device Configuration Backup Tool
-#After=network-online.target multi-user.target
-#Wants=network-online.target
+After=network-online.target multi-user.target
+Wants=network-online.target
[Service]
ExecStart=/usr/local/bin/oxidized
diff --git a/lib/oxidized/model/ipos.rb b/lib/oxidized/model/ipos.rb
index 5efd831..938f12d 100644
--- a/lib/oxidized/model/ipos.rb
+++ b/lib/oxidized/model/ipos.rb
@@ -3,7 +3,7 @@ class IPOS < Oxidized::Model
# Ericsson SSR (IPOS)
# Redback SE (SEOS)
- prompt /^([\[\]\w.@-]+[#>]\s?)$/
+ prompt /^([\[\]\w.@-]+[#:>]\s?)$/
comment '! '
cmd 'show chassis' do |cfg|
@@ -52,6 +52,12 @@ class IPOS < Oxidized::Model
cfg :telnet, :ssh do
post_login 'terminal length 0'
+ if vars :enable
+ post_login do
+ cmd "enable"
+ cmd vars(:enable)
+ end
+ end
pre_logout do
send "exit\n"
send "n\n"
diff --git a/lib/oxidized/model/xos.rb b/lib/oxidized/model/xos.rb
index 6f1323f..90f6f4a 100644
--- a/lib/oxidized/model/xos.rb
+++ b/lib/oxidized/model/xos.rb
@@ -29,6 +29,10 @@ class XOS < Oxidized::Model
cmd 'show configuration'
+ cmd 'show policy detail' do |cfg|
+ comment cfg
+ end
+
cfg :telnet do
username /^login:/
password /^\r*password:/