summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2014-07-17Merge branch 'master' of https://github.com/ytti/oxidizedSaku Ytti
2014-07-17bump up gemspec version0.0.65Saku Ytti
2014-07-14Merge pull request #24 from RichiH/patch-5ytti
core.rb: Improve error message
2014-07-14core.rb: Improve error messageRichard Hartmann
2014-07-14Fix powerconnect modelSaku Ytti
a) put metainformation on top, rancid style b) remove changing data from 'show system'
2014-07-14Allow it to work without local existing configSaku Ytti
Even after manually setting author+committer, it still crashed with: Config value 'user.name' was not found [Rugged::ConfigError] Not sure where it would want to use it, after author+committer already are set, but I guess this method is more robust anyhow.
2014-07-13Explain how to disable oxidized-web if load errorSaku Ytti
Ratioinale is, we want to keep it default, but it should be easy for people to understand what to do, if they don't want it. Closes #17
2014-07-13Change from grit to ruggedSaku Ytti
a) grit is not supported, rugged is b) grit requires git CLI installed, rugged does not c) grit needs monkey patching to work, rugged does not Closes #21 Closes #22
2014-07-11bump up gemspec version0.0.64Saku Ytti
2014-07-11reset retry count on successSaku Ytti
2014-07-11add support for retrying failed attemptsSaku Ytti
Looks like this in syslog: Jul 11 21:05:53 ytti oxidized[9820]: 10.10.10.10 raised Errno::ENETUNREACH with msg "Network is unreachable - connect(2) for "10.10.10.10" port 22" Jul 11 21:05:53 ytti oxidized[9820]: 10.10.10.10 raised Errno::ENETUNREACH with msg "Network is unreachable - connect(2) for "10.10.10.10" port 23" Jul 11 21:05:54 ytti oxidized[9820]: 10.10.10.10 status no_connection, retry attempt 1 Jul 11 21:05:54 ytti oxidized[9820]: 10.10.10.10 raised Errno::ENETUNREACH with msg "Network is unreachable - connect(2) for "10.10.10.10" port 22" Jul 11 21:05:54 ytti oxidized[9820]: 10.10.10.10 raised Errno::ENETUNREACH with msg "Network is unreachable - connect(2) for "10.10.10.10" port 23" Jul 11 21:05:55 ytti oxidized[9820]: 10.10.10.10 status no_connection, retry attempt 2 Jul 11 21:05:55 ytti oxidized[9820]: 10.10.10.10 raised Errno::ENETUNREACH with msg "Network is unreachable - connect(2) for "10.10.10.10" port 22" Jul 11 21:05:55 ytti oxidized[9820]: 10.10.10.10 raised Errno::ENETUNREACH with msg "Network is unreachable - connect(2) for "10.10.10.10" port 23" Jul 11 21:05:56 ytti oxidized[9820]: 10.10.10.10 status no_connection, retry attempt 3 Jul 11 21:05:56 ytti oxidized[9820]: 10.10.10.10 raised Errno::ENETUNREACH with msg "Network is unreachable - connect(2) for "10.10.10.10" port 22" Jul 11 21:05:56 ytti oxidized[9820]: 10.10.10.10 raised Errno::ENETUNREACH with msg "Network is unreachable - connect(2) for "10.10.10.10" port 23" Jul 11 21:05:57 ytti oxidized[9820]: 10.10.10.10 status no_connection, retries exhausted, giving up
2014-07-11ignore empty lines in CSV sourceSaku Ytti
Closes #23
2014-07-11Bit friendlier error message on invalid configSaku Ytti
Closes #20 [ytti@ytti.fi ~/tmp/oxidized]% oxidized Error loading config: (<unknown>): mapping values are not s context at line 15 column 7 [ytti@ytti.fi ~/tmp/oxidized]%
2014-07-11support local modelsSaku Ytti
if ~/.config/oxidized/model/ios.rb exists it is used, iinstead of the system-wide model
2014-07-11bump up gemspec version0.0.63Saku Ytti
2014-07-11create config dir, before pointing log file thereSaku Ytti
thanks to @richih
2014-07-09bump up gemspecSaku Ytti
2014-07-09Require OpenStructSaku Ytti
How this works in ruby2.0 normally? What component has loaded this implicitly? Thanks to @RichiH for spotting.
2014-07-09Merge pull request #18 from RichiH/feature--README_prerequisitesytti
README.md: Require ruby-dev on Debian
2014-07-09README.md: Require ruby-dev on DebianRichard Hartmann
2014-07-09Merge pull request #16 from RichiH/feature--web_optionalytti
Default to local listening for oxidized-web
2014-07-09Default to local listening for oxidized-webRichard Hartmann
2014-07-09Merge pull request #15 from RichiH/patch-3ytti
README.md: Make optional oxidized-web really optional
2014-07-09README.md: Make optional oxidized-web really optionalRichard Hartmann
2014-07-09fixed #13Samer Abdel-Hafez
2014-07-09Merge pull request #12 from RichiH/patch-2ytti
README.md: Formatting
2014-07-09Merge pull request #11 from RichiH/patch-1ytti
README.md: Install ruby as well
2014-07-09README.md: FormattingRichard Hartmann
2014-07-09README.md: Install ruby as wellRichard Hartmann
2014-07-04match node[:name] to ipSaku Ytti
When running Oxidized via oxidized-script you want just one node, and you specify that as Nodes.new(:node=>x) however as router.db usually lacks 'ip' field, and only has 'name' field'. If you have router.db with IP in 'name' field, and you do Nodes.new(:node='192.0.2.1') it won't return anything, as '192.0.2.1' is matched against node[:ip] which does not exist. This change makes IP match against IP and Name.
2014-07-03Fix class name resolutionSaku Ytti
In new method, where we no long explicitly set loaded class name for later resolution we depend on file name being same as class name. However for File output, this is not true, because I didn't want plain File in code to resolve to Oxidized::File, and din't want to always write ::File, File ouput has class name OxFile. This change allows class names to start optionally with string 'Oxidized' if so, they still match.
2014-07-03Merge branch 'master' of https://github.com/ytti/oxidizedSaku Ytti
2014-07-03bump up gemspecSaku Ytti
2014-06-11Fix dynamic loading matchSaku Ytti
We can't use #match, if IOSXR is seen in source list before IOS, then IOS will #match on IOSXR class and wrong model is used for IOS devices. And obviously stupid to use regexp if you don't atbsolutely have to.
2014-06-11mention TREX preso in readmeSaku Ytti
2014-06-11Change dynamic discover of file => class nameSaku Ytti
We needed this, because use of 'def inherited' not idempotent, in Oxidized::Script use case we may need to restart Oxidized, even though it's already loaded, and we won't get class names populated via 'def inherited' anymore. There are quite many optiosn to do this a) filename == class name + no discovery/mapping, very clean - user 'source' must give us model name in exactly right capitalization b) add 'self' at end of files, so eval will return class name + deterministic with arbitrary name - DSL cruft, DSL being light is our main value (can we do this via parent class? I couldn't find way) c) load in new module via Module.module_eval X + module will contain only consts we just created - but which one is the one we want? - if we use eval, load errors won't tell line error But at least now we got rid of 'inherited' methods and not adding too much cruft, hope it's better than before.
2014-06-11move :remove_secret to varsSamer Abdel-Hafez
2014-06-11add secrets removal code + bump versionSamer Abdel-Hafez
2014-06-06fix: node#last= didn't handle nilAnton Aksola
temporary fix. Maybe node#last should check the type or we shouldn't use last for the nodes#next in the first place
2014-06-06fix: handle group in output git#fetchAnton Aksola
2014-05-16don't store error Node raisedSaku Ytti
We may need this in future, but as we don't need this in oxidized-script now after all, I don't want something to be implemented just-in-case
2014-05-16store error node#run raisedSaku Ytti
2014-05-07Save stats/last status during Nodes#load0.0.58Saku Ytti
We probably should just axe Node#last, as Node#stats contains all it does and more. However it would need changing web views and I'm too lazy for that right now. Perhaps Nodes/Node also needs some unique ID so two instances of Nodes can be compared exactly. Right now copying the old stats relies on name being identical, but can we trust name to be unique? Even with groups support?
2014-05-07Add support for node stats0.0.57Saku Ytti
Bumpup gemspec
2014-05-07Stats for nodeSaku Ytti
So that we can easily check last time node failed/succceded etc
2014-05-06require config/vars earlier0.0.56Saku Ytti
- we need config/vars before model - some whitespace changes Bump up gemspec
2014-05-05missing editsAnton Aksola
2014-05-05Fixed crash if node vars_map not setAnton Aksola
in addition: - move vars helper to separate file - add csv support for node variables
2014-05-05Introduce node and group level varsAnton Aksola
Variables can now be fed to model from multiple locations. In order of preference: 1) node (from source) 2) group 3) global In a model vars should be accessed via 'vars' helper method though it is not required. Helper method ignores nil values so care needs to taken when designing model behaviour. Support for node level vars is currently available on sql source via 'vars_map' configuration. Following example populates node vars 'enable' and 'somevariable' from sql columns 'var_enable' and 'var_somevariable' sql: adapter: sqlite file: /home/aakso/.config/oxidized/sqrouter.db table: nodes map: name: hostname model: model group: node_group username: username password: password vars_map: enable: var_enablepw somevariable: var_somevariable
2014-05-02Introduce group level configuration for authAnton Aksola
For rancid-like behaviour one can now set username and password for node groups. These parameters are considered in the following order: 1) node parameters (from source) 2) group level parameters 3) global level parameters example configuration for group 'testlab' groups: testlab: username: testuser password: testpassword