blob: e0d4c0ab611ba40dfed5a1adcc3eb21b1e0ef192 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
class OpenGear < Oxidized::Model
comment '# '
prompt /^(\$\s)?$/
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
|