diff options
author | Jacob Thomas <jacob@doogie.consulting> | 2016-02-02 21:54:27 -0500 |
---|---|---|
committer | Jacob Thomas <jacob@doogie.consulting> | 2016-02-02 21:54:27 -0500 |
commit | e3d1a614e7a1d4ee5cf6983cc2bddcb0c64bb975 (patch) | |
tree | b29dee8d51cf9922b49613d4226a453527fad425 /lib | |
parent | 550a20c9ac0b6f69b91cab9b3d20688a0e7d1bd0 (diff) | |
parent | 52eaba0e15c7808949c0821a318376c17b281a12 (diff) |
Merge remote-tracking branch 'ytti/master'
Diffstat (limited to 'lib')
-rw-r--r-- | lib/oxidized/model/opengear.rb | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/lib/oxidized/model/opengear.rb b/lib/oxidized/model/opengear.rb new file mode 100644 index 0000000..7f801f8 --- /dev/null +++ b/lib/oxidized/model/opengear.rb @@ -0,0 +1,19 @@ +class OpenGear < Oxidized::Model + + comment '# ' + + cmd :secret do |cfg| + cfg.gsub!(/password (\S+)/, 'password <secret removed>') + cfg.gsub!(/community (\S+)/, 'community <secret removed>') + cfg + end + + cmd('cat /etc/version') { |cfg| comment cfg } + + cmd 'config -g config' + + cfg :ssh do + exec true # don't run shell, run each command in exec channel + end + +end |