summaryrefslogtreecommitdiff
path: root/templates
diff options
context:
space:
mode:
authorAlex Harpin <development@landsofshadow.co.uk>2015-11-21 08:54:45 +0000
committerAlex Harpin <development@landsofshadow.co.uk>2015-11-21 08:54:45 +0000
commit074782df3af55e7c685932bdcdb66782533c1343 (patch)
treee46f4537b61a6d96c70dfc81308452acb98eac64 /templates
parent9e151713e2397edf811ab8fc6abead9126d238ca (diff)
downloadvyatta-op-074782df3af55e7c685932bdcdb66782533c1343.tar.gz
vyatta-op-074782df3af55e7c685932bdcdb66782533c1343.zip
vyatta-op: add restart cli command for ssh
Add a CLI op mode command to allow restarting of the SSH service without having to update the configuration. Bug #514 http://bugzilla.vyos.net/show_bug.cgi?id=514
Diffstat (limited to 'templates')
-rw-r--r--templates/restart/ssh/node.def9
1 files changed, 9 insertions, 0 deletions
diff --git a/templates/restart/ssh/node.def b/templates/restart/ssh/node.def
new file mode 100644
index 0000000..c8f59a9
--- /dev/null
+++ b/templates/restart/ssh/node.def
@@ -0,0 +1,9 @@
+help: Restart SSH service
+
+run:
+ echo "Restarting SSH..."
+ sudo /usr/sbin/invoke-rc.d ssh restart
+ if [[ $? -eq 0 ]]; then
+ echo "Success!"
+ fi
+