[ARVADOS] updated: b26951c6f488f28cf1ea5aac65c65311d0b573a4

git at public.curoverse.com git at public.curoverse.com
Wed Feb 3 06:26:39 EST 2016


Summary of changes:
 services/login-sync/bin/arvados-login-sync | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

       via  b26951c6f488f28cf1ea5aac65c65311d0b573a4 (commit)
      from  95773bc4ac9e01126a80a96fdbe0bf37d1478767 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.


commit b26951c6f488f28cf1ea5aac65c65311d0b573a4
Author: Brett Smith <brett at curoverse.com>
Date:   Wed Feb 3 06:26:32 2016 -0500

    login-sync gets user's home from /etc/passwd.
    
    No issue #.

diff --git a/services/login-sync/bin/arvados-login-sync b/services/login-sync/bin/arvados-login-sync
index c92fc9b..e1b8c48 100755
--- a/services/login-sync/bin/arvados-login-sync
+++ b/services/login-sync/bin/arvados-login-sync
@@ -68,7 +68,6 @@ begin
   logins.each do |l|
     next if seen[l[:username]]
     seen[l[:username]] = true if not seen.has_key?(l[:username])
-    @homedir = "/home/#{l[:username]}"
 
     unless uids[l[:username]]
       STDERR.puts "Creating account #{l[:username]}"
@@ -85,6 +84,7 @@ begin
                          out: devnull)
     end
     # Create .ssh directory if necessary
+    @homedir = Etc.getpwnam(l[:username]).dir
     userdotssh = File.join(@homedir, ".ssh")
     Dir.mkdir(userdotssh) if !File.exists?(userdotssh)
     @key = "#######################################################################################
@@ -109,4 +109,3 @@ rescue Exception => bang
   puts bang.backtrace.join("\n")
   exit 1
 end
-

-----------------------------------------------------------------------


hooks/post-receive
-- 




More information about the arvados-commits mailing list