oxidized 0.17.0 → 0.18.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +6 -1
- data/Gemfile.lock +1 -1
- data/README.md +83 -63
- data/extra/oxidized.apache2 +14 -0
- data/extra/oxidized.nginx +14 -0
- data/lib/oxidized/model/aosw.rb +2 -2
- data/lib/oxidized/model/apc_aos.rb +11 -0
- data/lib/oxidized/model/ironware.rb +6 -6
- data/lib/oxidized/source/csv.rb +1 -1
- data/lib/oxidized/source/http.rb +1 -1
- data/lib/oxidized/source/sql.rb +1 -1
- data/lib/oxidized/version.rb +1 -1
- metadata +5 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f88947ee1d76a827ebd27c7bed550316840adb77
|
4
|
+
data.tar.gz: ed10ff21f48f72e1f447ea4c1a6f2c47f07affe1
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 210d315e689781ffc62d5d64faff5f6cf6be4e6e5178703d4f30026be62dab6764987f85cb8eb406aa456f96e074fc6d8a47f7ce7a4df66e106ee099c9d9d179
|
7
|
+
data.tar.gz: 65ab67187988d2fbc67cea78498b9cd6dd5b4ba35a0c9e871079eaa840c0f66f930b4c89b59bc20041b0f8cc4bd58f990d22e4f811fd668cd10cf100dbf3cfd7
|
data/CHANGELOG.md
CHANGED
@@ -1,4 +1,9 @@
|
|
1
|
-
# 0
|
1
|
+
# 0.18.0
|
2
|
+
- FEATURE: APC model (by @davromaniak )
|
3
|
+
- BUGFIX: ironware, aosw
|
4
|
+
- BUGFIX: interpolate nil, false, true for node vars too
|
5
|
+
|
6
|
+
# 0 17.0
|
2
7
|
- FEATURE: "nil", "false" and "true" in source (e.g. router.db) are interpeted as nil, false, true. Empty is now always considered empty string, instead of in some cases nil and some cases empty string.
|
3
8
|
- FEATURE: support tftp as input model (@MajesticFalcon)
|
4
9
|
- FEATURE: add alvarion model (@MajesticFalcon)
|
data/Gemfile.lock
CHANGED
data/README.md
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
# Oxidized [![Build Status](https://travis-ci.org/Shopify/oxidized.svg)](https://travis-ci.org/Shopify/oxidized) [![Gem Version](https://badge.fury.io/rb/oxidized.svg)](http://badge.fury.io/rb/oxidized) [![Join the chat at https://gitter.im/oxidized/Lobby](https://badges.gitter.im/oxidized/Lobby.svg)](https://gitter.im/oxidized/Lobby?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
|
1
|
+
# Oxidized [![Build Status](https://travis-ci.org/Shopify/oxidized.svg)](https://travis-ci.org/Shopify/oxidized) [![Gem Version](https://badge.fury.io/rb/oxidized.svg)](http://badge.fury.io/rb/oxidized) [![Join the chat at https://gitter.im/oxidized/Lobby](https://badges.gitter.im/oxidized/Lobby.svg)](https://gitter.im/oxidized/Lobby?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
|
2
2
|
|
3
3
|
Oxidized is a network device configuration backup tool. It's a RANCID replacement!
|
4
4
|
|
@@ -45,102 +45,104 @@ Oxidized is a network device configuration backup tool. It's a RANCID replacemen
|
|
45
45
|
|
46
46
|
# Supported OS types
|
47
47
|
* Vendor
|
48
|
-
* OS
|
48
|
+
* OS model
|
49
49
|
|
50
50
|
* A10 Networks
|
51
|
-
* ACOS
|
51
|
+
* [ACOS](lib/oxidized/model/acos.rb)
|
52
52
|
* Alcatel-Lucent
|
53
|
-
* AOS
|
54
|
-
* AOS7
|
55
|
-
* ISAM
|
53
|
+
* [AOS](lib/oxidized/model/aos.rb)
|
54
|
+
* [AOS7](lib/oxidized/model/aos7.rb)
|
55
|
+
* [ISAM](lib/oxidized/model/isam.rb)
|
56
56
|
* Wireless
|
57
57
|
* Alvarion
|
58
|
-
* BreezeACCESS
|
58
|
+
* [BreezeACCESS](lib/oxidized/model/alvarion.rb)
|
59
|
+
* APC
|
60
|
+
* [AOS](lib/oxidized/model/apc_aos.rb)
|
59
61
|
* Arista
|
60
|
-
* EOS
|
62
|
+
* [EOS](lib/oxidized/model/eos.rb)
|
61
63
|
* Arris
|
62
|
-
* C4CMTS
|
64
|
+
* [C4CMTS](lib/oxidized/model/c4cmts.rb)
|
63
65
|
* Aruba
|
64
|
-
* AOSW
|
66
|
+
* [AOSW](lib/oxidized/model/aosw.rb)
|
65
67
|
* Brocade
|
66
|
-
* FabricOS
|
67
|
-
* Ironware
|
68
|
-
* NOS (Network Operating System)
|
69
|
-
* Vyatta
|
70
|
-
* 6910
|
68
|
+
* [FabricOS](lib/oxidized/model/fabricos.rb)
|
69
|
+
* [Ironware](lib/oxidized/model/ironware.rb)
|
70
|
+
* [NOS (Network Operating System)](lib/oxidized/model/nos.rb)
|
71
|
+
* [Vyatta](lib/oxidized/model/vyatta.rb)
|
72
|
+
* [6910](lib/oxidized/model/br6910.rb)
|
71
73
|
* Check Point
|
72
|
-
* GaiaOS
|
74
|
+
* [GaiaOS](lib/oxidized/model/gaiaos.rb)
|
73
75
|
* Ciena
|
74
|
-
* SOAS
|
76
|
+
* [SOAS](lib/oxidized/model/saos.rb)
|
75
77
|
* Cisco
|
76
|
-
* AireOS
|
77
|
-
* ASA
|
78
|
-
* CatOS
|
79
|
-
* IOS
|
80
|
-
* IOSXR
|
81
|
-
* NXOS
|
82
|
-
* SMB (Nikola series)
|
78
|
+
* [AireOS](lib/oxidized/model/aireos.rb)
|
79
|
+
* [ASA](lib/oxidized/model/asa.rb)
|
80
|
+
* [CatOS](lib/oxidized/model/catos.rb)
|
81
|
+
* [IOS](lib/oxidized/model/ios.rb)
|
82
|
+
* [IOSXR](lib/oxidized/model/iosxr.rb)
|
83
|
+
* [NXOS](lib/oxidized/model/nxos.rb)
|
84
|
+
* [SMB (Nikola series)](lib/oxidized/model/ciscosmb.rb)
|
83
85
|
* Citrix
|
84
|
-
* NetScaler (Virtual Applicance)
|
86
|
+
* [NetScaler (Virtual Applicance)](lib/oxidized/model/netscaler.rb)
|
85
87
|
* Coriant (former Tellabs)
|
86
|
-
* TMOS (8800)
|
87
|
-
* 8600
|
88
|
+
* [TMOS (8800)](lib/oxidized/model/corianttmos.rb)
|
89
|
+
* [8600](lib/oxidized/model/coriant8600.rb)
|
88
90
|
* Cumulus
|
89
|
-
* Linux
|
91
|
+
* [Linux](lib/oxidized/model/cumulus.rb)
|
90
92
|
* DataCom
|
91
|
-
* DmSwitch 3000
|
93
|
+
* [DmSwitch 3000](lib/oxidized/model/datacom.rb)
|
92
94
|
* DELL
|
93
|
-
* PowerConnect
|
94
|
-
* AOSW
|
95
|
+
* [PowerConnect](lib/oxidized/model/powerconnect.rb)
|
96
|
+
* [AOSW](lib/oxidized/model/aosw.rb)
|
95
97
|
* Ericsson/Redback
|
96
|
-
* IPOS (former SEOS)
|
98
|
+
* [IPOS (former SEOS)](lib/oxidized/model/ipos.rb)
|
97
99
|
* Extreme Networks
|
98
|
-
* XOS
|
99
|
-
* WM
|
100
|
+
* [XOS](lib/oxidized/model/xos.rb)
|
101
|
+
* [WM](lib/oxidized/model/mtrlrfs.rb)
|
100
102
|
* F5
|
101
|
-
* TMOS
|
103
|
+
* [TMOS](lib/oxidized/model/tmos.rb)
|
102
104
|
* Force10
|
103
|
-
* DNOS
|
104
|
-
* FTOS
|
105
|
+
* [DNOS](lib/oxidized/model/dnos.rb)
|
106
|
+
* [FTOS](lib/oxidized/model/ftos.rb)
|
105
107
|
* FortiGate
|
106
|
-
* FortiOS
|
108
|
+
* [FortiOS](lib/oxidized/model/fortios.rb)
|
107
109
|
* HP
|
108
|
-
* Comware (HP A-series, H3C, 3Com)
|
109
|
-
* Procurve
|
110
|
+
* [Comware (HP A-series, H3C, 3Com)](lib/oxidized/model/comware.rb)
|
111
|
+
* [Procurve](lib/oxidized/model/procurve.rb)
|
110
112
|
* Huawei
|
111
|
-
* VRP
|
113
|
+
* [VRP](lib/oxidized/model/vrp.rb)
|
112
114
|
* Juniper
|
113
|
-
* JunOS
|
114
|
-
* ScreenOS (Netscreen)
|
115
|
+
* [JunOS](lib/oxidized/model/junos.rb)
|
116
|
+
* [ScreenOS (Netscreen)](lib/oxidized/model/screenos.rb)
|
115
117
|
* Mellanox
|
116
|
-
* MLNX-OS
|
118
|
+
* [MLNX-OS](lib/oxidized/model/mlnxos.rb)
|
117
119
|
* Mikrotik
|
118
|
-
* RouterOS
|
120
|
+
* [RouterOS](lib/oxidized/model/routeros.rb)
|
119
121
|
* Motorola
|
120
|
-
* RFS
|
122
|
+
* [RFS](lib/oxidized/model/mtrlrfs.rb)
|
121
123
|
* MRV
|
122
|
-
* MasterOS
|
124
|
+
* [MasterOS](lib/oxidized/model/masteros.rb)
|
123
125
|
* Netonix
|
124
|
-
* WISP Switch (As Netonix)
|
126
|
+
* [WISP Switch (As Netonix)](lib/oxidized/model/netonix.rb)
|
125
127
|
* Nokia (formerly TiMetra, Alcatel, Alcatel-Lucent)
|
126
|
-
* SR OS (TiMOS)
|
128
|
+
* [SR OS (TiMOS)](lib/oxidized/model/timos.rb)
|
127
129
|
* Opengear
|
128
|
-
* Opengear
|
130
|
+
* [Opengear](lib/oxidized/model/opengear.rb)
|
129
131
|
* Palo Alto
|
130
|
-
* PANOS
|
131
|
-
* pfSense
|
132
|
+
* [PANOS](lib/oxidized/model/panos.rb)
|
133
|
+
* [pfSense](lib/oxidized/model/pfsense.rb)
|
132
134
|
* Quanta
|
133
|
-
* Quanta / VxWorks 6.6 (1.1.0.8)
|
135
|
+
* [Quanta / VxWorks 6.6 (1.1.0.8)](lib/oxidized/model/quantaos.rb)
|
134
136
|
* Supermicro
|
135
|
-
* Supermicro
|
137
|
+
* [Supermicro](lib/oxidized/model/supermicro.rb)
|
136
138
|
* Ubiquiti
|
137
|
-
* AirOS
|
138
|
-
* Edgeos
|
139
|
-
* EdgeSwitch
|
139
|
+
* [AirOS](lib/oxidized/model/airos.rb)
|
140
|
+
* [Edgeos](lib/oxidized/model/edgeos.rb)
|
141
|
+
* [EdgeSwitch](lib/oxidized/model/edgeswitch.rb)
|
140
142
|
* Watchguard
|
141
|
-
* Fireware OS
|
143
|
+
* [Fireware OS](lib/oxidized/model/firewareos.rb)
|
142
144
|
* Zyxel
|
143
|
-
* ZyNOS
|
145
|
+
* [ZyNOS](lib/oxidized/model/zynos.rb)
|
144
146
|
|
145
147
|
|
146
148
|
# Installation
|
@@ -286,6 +288,24 @@ _Note: this step in only needed for creating Oxidized's configuration file and c
|
|
286
288
|
```
|
287
289
|
docker run --rm -v /etc/oxidized:/root/.config/oxidized -p 8888:8888/tcp -t oxidized/oxidized:latest oxidized
|
288
290
|
```
|
291
|
+
If the RESTful API and Web Interface are enabled, on the docker host running the container
|
292
|
+
edit /etc/oxidized/config and modify 'rest: 127.0.0.1:8888' by 'rest: 0.0.0.0:8888'
|
293
|
+
this will bind port 8888 to all interfaces then expose port out. (Issue #445)
|
294
|
+
|
295
|
+
You can also use docker-compose to launch oxidized container:
|
296
|
+
```
|
297
|
+
# docker-compose.yml
|
298
|
+
# docker-compose file example for oxidized that will start along with docker daemon
|
299
|
+
oxidized:
|
300
|
+
restart: always
|
301
|
+
image: oxidized/oxidized:latest
|
302
|
+
ports:
|
303
|
+
- 8888:8888/tcp
|
304
|
+
environment:
|
305
|
+
CONFIG_RELOAD_INTERVAL: 600
|
306
|
+
volumes:
|
307
|
+
- /etc/oxidized:/root/.config/oxidized
|
308
|
+
```
|
289
309
|
|
290
310
|
create the `/etc/oxidized/router.db`
|
291
311
|
|
@@ -347,10 +367,10 @@ Device models can contain substitution filters to remove potentially sensitive d
|
|
347
367
|
|
348
368
|
As a partial example from ios.rb:
|
349
369
|
|
350
|
-
```
|
370
|
+
```
|
351
371
|
cmd :secret do |cfg|
|
352
372
|
cfg.gsub! /^(snmp-server community).*/, '\\1 <configuration removed>'
|
353
|
-
(...)
|
373
|
+
(...)
|
354
374
|
cfg
|
355
375
|
end
|
356
376
|
```
|
@@ -416,10 +436,10 @@ source:
|
|
416
436
|
adapter: mysql2
|
417
437
|
database: oxidized
|
418
438
|
table: nodes
|
419
|
-
username: root
|
439
|
+
username: root
|
420
440
|
password: rootpass
|
421
441
|
map:
|
422
|
-
name: ip
|
442
|
+
name: ip
|
423
443
|
model: model
|
424
444
|
username: username
|
425
445
|
password: password
|
@@ -0,0 +1,14 @@
|
|
1
|
+
<VirtualHost *:80>
|
2
|
+
# Place in sites-available
|
3
|
+
|
4
|
+
ServerAdmin admin@example.com
|
5
|
+
ServerName oxidized.example.com
|
6
|
+
ServerAlias oxidized
|
7
|
+
|
8
|
+
ProxyPass / http://127.0.0.1:8888/
|
9
|
+
ProxyPassReverse / http://127.0.0.1:8888/
|
10
|
+
|
11
|
+
ErrorLog /var/log/apache2/oxidized_error.log
|
12
|
+
CustomLog /var/log/apache2/oxidized_access.log combined
|
13
|
+
|
14
|
+
</VirtualHost>
|
data/lib/oxidized/model/aosw.rb
CHANGED
@@ -2,14 +2,14 @@ class IronWare < Oxidized::Model
|
|
2
2
|
|
3
3
|
prompt /^.*(telnet|ssh)\@.+[>#]\s?$/i
|
4
4
|
comment '! '
|
5
|
-
|
5
|
+
|
6
6
|
#to handle pager without enable
|
7
7
|
#expect /^((.*)--More--(.*))$/ do |data, re|
|
8
8
|
# send ' '
|
9
9
|
# data.sub re, ''
|
10
10
|
#end
|
11
11
|
|
12
|
-
|
12
|
+
|
13
13
|
#to remove backspace (if handle pager without enable)
|
14
14
|
#expect /^((.*)[\b](.*))$/ do |data, re|
|
15
15
|
# data.sub re, ''
|
@@ -44,14 +44,14 @@ class IronWare < Oxidized::Model
|
|
44
44
|
out << sc.rest
|
45
45
|
cfg = out
|
46
46
|
end
|
47
|
-
|
47
|
+
|
48
48
|
comment cfg
|
49
49
|
end
|
50
|
-
|
50
|
+
|
51
51
|
cmd 'show flash' do |cfg|
|
52
52
|
comment cfg
|
53
53
|
end
|
54
|
-
|
54
|
+
|
55
55
|
cmd 'show module' do |cfg|
|
56
56
|
cfg.gsub! /^((Invalid input)|(Type \?)).*$/, '' # some ironware devices are fixed config
|
57
57
|
comment cfg
|
@@ -74,7 +74,7 @@ class IronWare < Oxidized::Model
|
|
74
74
|
if vars :enable
|
75
75
|
post_login do
|
76
76
|
send "enable\r\n"
|
77
|
-
|
77
|
+
cmd vars(:enable)
|
78
78
|
end
|
79
79
|
end
|
80
80
|
post_login ''
|
data/lib/oxidized/source/csv.rb
CHANGED
data/lib/oxidized/source/http.rb
CHANGED
data/lib/oxidized/source/sql.rb
CHANGED
@@ -26,7 +26,7 @@ class SQL < Source
|
|
26
26
|
query.each do |node|
|
27
27
|
# map node parameters
|
28
28
|
keys = {}
|
29
|
-
@cfg.map.each { |key, sql_column| keys[key.to_sym] = node[sql_column.to_sym] }
|
29
|
+
@cfg.map.each { |key, sql_column| keys[key.to_sym] = node_var_interpolate node[sql_column.to_sym] }
|
30
30
|
keys[:model] = map_model keys[:model] if keys.key? :model
|
31
31
|
|
32
32
|
# map node specific vars
|
data/lib/oxidized/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: oxidized
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.18.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Saku Ytti
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2016-
|
13
|
+
date: 2016-10-14 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: asetus
|
@@ -182,8 +182,10 @@ files:
|
|
182
182
|
- extra/auto-reload-config.runit
|
183
183
|
- extra/nagios_check_failing_nodes.rb
|
184
184
|
- extra/oxidized-report-git-commits
|
185
|
+
- extra/oxidized.apache2
|
185
186
|
- extra/oxidized.init
|
186
187
|
- extra/oxidized.init.d
|
188
|
+
- extra/oxidized.nginx
|
187
189
|
- extra/oxidized.runit
|
188
190
|
- extra/oxidized.service
|
189
191
|
- extra/oxidized.supervisord
|
@@ -216,6 +218,7 @@ files:
|
|
216
218
|
- lib/oxidized/model/aos.rb
|
217
219
|
- lib/oxidized/model/aos7.rb
|
218
220
|
- lib/oxidized/model/aosw.rb
|
221
|
+
- lib/oxidized/model/apc_aos.rb
|
219
222
|
- lib/oxidized/model/asa.rb
|
220
223
|
- lib/oxidized/model/br6910.rb
|
221
224
|
- lib/oxidized/model/c4cmts.rb
|