store sliver ssh keys in the root /home and rely on the mounting vsys script to expose it
authorThierry Parmentelat <thierry.parmentelat@sophia.inria.fr>
Thu, 1 Jul 2010 14:48:31 +0000 (14:48 +0000)
committerThierry Parmentelat <thierry.parmentelat@sophia.inria.fr>
Thu, 1 Jul 2010 14:48:31 +0000 (14:48 +0000)
plugins/sliverauth.py

index 9ff2f38..06c5c22 100644 (file)
@@ -92,7 +92,11 @@ def manage_hmac (plc, sliver):
 
 # create the key if needed and returns the key contents
 def generate_sshkey (sliver): 
-    keyfile="/vservers/%s/home/%s/.ssh/id_rsa"%(sliver['name'],sliver['name'])
+# initial version was storing stuff in the sliver directly
+#    keyfile="/vservers/%s/home/%s/.ssh/id_rsa"%(sliver['name'],sliver['name'])
+# we're now storing this in the same place as the authorized_keys, which in turn
+# gets mounted to the user's home directory in the sliver
+    keyfile="/home/%s/.ssh/id_rsa"%(sliver['name'],sliver['name'])
     pubfile="%s.pub"%keyfile
     dotssh=os.path.dirname(keyfile)
     # create dir if needed