git://git.onelab.eu
/
nodemanager.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2fbc810
)
Custom shell to allow a user to connect to its sliver using the slice_name.
author
Xavi Leon
<xleon@ac.upc.edu>
Thu, 10 Nov 2011 17:08:31 +0000
(12:08 -0500)
committer
Xavi Leon
<xleon@ac.upc.edu>
Thu, 10 Nov 2011 17:08:31 +0000
(12:08 -0500)
sshsh
[new file with mode: 0755]
patch
|
blob
diff --git a/sshsh
b/sshsh
new file mode 100755
(executable)
index 0000000..
edcd667
--- /dev/null
+++ b/
sshsh
@@ -0,0
+1,5
@@
+#!/bin/bash
+MAC=$(virsh --connect lxc:// --readonly dumpxml $USER|grep mac|awk -F\' '{print $2}')
+IP=$(cat /var/lib/libvirt/dnsmasq/default.leases | grep $MAC | awk '{print $3}')
+shift
+ssh root@$IP "$@"