summaryrefslogtreecommitdiff
path: root/README.md
diff options
context:
space:
mode:
Diffstat (limited to 'README.md')
-rw-r--r--README.md69
1 files changed, 61 insertions, 8 deletions
diff --git a/README.md b/README.md
index 82c33a5..2f3defc 100644
--- a/README.md
+++ b/README.md
@@ -148,12 +148,16 @@ Oxidized is a network device configuration backup tool. It's a RANCID replacemen
* [Supermicro](lib/oxidized/model/supermicro.rb)
* Trango Systems
* [Trango](lib/oxidized/model/trango.rb)
+ * TPLink
+ * [TPLink](lib/oxidized/model/tplink.rb)
* Ubiquiti
* [AirOS](lib/oxidized/model/airos.rb)
* [Edgeos](lib/oxidized/model/edgeos.rb)
* [EdgeSwitch](lib/oxidized/model/edgeswitch.rb)
* Watchguard
* [Fireware OS](lib/oxidized/model/firewareos.rb)
+ * Zhone
+ * [Zhone (OLT and MX)](lib/oxidized/model/zhoneolt.rb)
* Zyxel
* [ZyNOS](lib/oxidized/model/zynos.rb)
@@ -186,6 +190,14 @@ gem install oxidized
gem install oxidized-script oxidized-web
```
+## Build from Git
+```shell
+git clone https://github.com/ytti/oxidized.git
+cd oxidized/
+gem build *.gemspec
+gem install pkg/*.gem
+```
+
# Configuration
Oxidized configuration is in YAML format. Configuration files are subsequently sourced from ```/etc/oxidized/config``` then ```~/.config/oxidized/config```. The hashes will be merged, this might be useful for storing source information in a system wide file and user specific configuration in the home directory (to only include a staff specific username and password). Eg. if many users are using ```oxs```, see [Oxidized::Script](https://github.com/ytti/oxidized-script).
@@ -233,12 +245,15 @@ oxidized
Now tell Oxidized where it finds a list of network devices to backup configuration from. You can either use CSV or SQLite as source. To create a CSV source add the following snippet:
+Note: If gpg is set to anything other than false it will attempt to decrypt the file contents
```
source:
default: csv
csv:
file: ~/.config/oxidized/router.db
delimiter: !ruby/regexp /:/
+ gpg: false
+ gpg_password: 'password'
map:
name: 0
model: 1
@@ -346,14 +361,18 @@ docker run -v /etc/oxidized:/root/.config/oxidized -p 8888:8888/tcp -e CONFIG_RE
## Cookbook
### Debugging
-In case a model plugin doesn't work correctly (ios, procurve, etc.), you can enable live debugging of SSH/Telnet sessions. Just add a ```debug``` option, specifying a log file destination to the ```input``` section.
+In case a model plugin doesn't work correctly (ios, procurve, etc.), you can enable live debugging of SSH/Telnet sessions. Just add a ```debug``` option containing the value true to the ```input``` section. The log files will be created depending on the parent directory of the logfile option.
-The following example will log an active ssh session to ```/home/fisakytt/.config/oxidized/log_input-ssh``` and telnet to ```log_input-telnet```. The file will be truncated on each consecutive ssh/telnet session, so you need to put a ```tailf``` or ```tail -f``` on that file!
+The following example will log an active ssh/telnet session ```/home/oxidized/.config/oxidized/log/<IP-Adress>-<PROTOCOL>```. The file will be truncated on each consecutive ssh/telnet session, so you need to put a ```tailf``` or ```tail -f``` on that file!
```
+log: /home/oxidized/.config/oxidized/log
+
+...
+
input:
default: ssh, telnet
- debug: /tmp/oxidized_log_input
+ debug: true
ssh:
secure: false
```
@@ -403,7 +422,7 @@ vars:
### Source: CSV
-One line per device, colon seperated.
+One line per device, colon seperated. If `ip` isn't present, a DNS lookup will be done against `name`. For large installations, setting `ip` will dramatically reduce startup time.
```
source:
@@ -413,11 +432,12 @@ source:
delimiter: !ruby/regexp /:/
map:
name: 0
- model: 1
- username: 2
- password: 3
+ ip: 1
+ model: 2
+ username: 3
+ password: 4
vars_map:
- enable: 4
+ enable: 5
```
### SSH Proxy Command
@@ -725,6 +745,16 @@ map:
group: 2
```
+### Triggered backups
+
+A node can be moved to head-of-queue via the REST API `GET/POST /node/next/[NODE]`.
+
+In the default configuration this node will be processed when the next job worker becomes available, it could take some time if existing backups are in progress. To execute moved jobs immediately a new job can be added:
+
+```
+next_adds_job: true
+```
+
# Hooks
You can define arbitrary number of hooks that subscribe different events. The hook system is modular and different kind of hook types can be enabled.
@@ -844,6 +874,29 @@ AWS SNS hook requires the following configuration keys:
Your AWS credentials should be stored in `~/.aws/credentials`.
+## Hook type: slackdiff
+
+The `slackdiff` hook posts colorized config diffs to a [Slack](http://www.slack.com) channel of your choice. It only triggers for `post_store` events.
+
+You will need to manually install the `slack-api` gem on your system:
+
+```
+gem install slack-api
+```
+
+Configuration example:
+
+``` yaml
+hooks:
+ slack:
+ type: slackdiff
+ events: [post_store]
+ token: SLACK_BOT_TOKEN
+ channel: "#network-changes"
+```
+
+Note the channel name must be in quotes.
+
# Ruby API
The following objects exist in Oxidized.