@@ -807,6 +807,12 @@ if Sys.isunix() # aka have ssh
807807 append! (hosts, localhost_aliases)
808808 end
809809
810+ # CI machines sometimes don't already have a .ssh directory
811+ ssh_dir = joinpath (homedir (), " .ssh" )
812+ if ! isdir (ssh_dir)
813+ mkdir (ssh_dir)
814+ end
815+
810816 print (" \n Testing SSH addprocs with $(length (hosts)) workers...\n " )
811817 new_pids = addprocs_with_testenv (hosts; sshflags= sshflags)
812818 @test length (new_pids) == length (hosts)
@@ -828,14 +834,13 @@ if Sys.isunix() # aka have ssh
828834 test_n_remove_pids (new_pids)
829835
830836 print (" \n ssh addprocs with tunnel (SSH multiplexing)\n " )
837+
838+ controlpath = joinpath (ssh_dir, " julia-$(ENV [" USER" ]) @localhost:2222" )
831839 new_pids = addprocs_with_testenv ([(" localhost" , num_workers)]; tunnel= true , multiplex= true , sshflags= sshflags)
832840 @test length (new_pids) == num_workers
833- mktempdir () do path
834- controlpath = joinpath (path, " julia-$(ENV [" USER" ]) @localhost:2222" )
835- @test issocket (controlpath)
836- test_n_remove_pids (new_pids)
837- @test :ok == timedwait (()-> ! issocket (controlpath), 10.0 ; pollint= 0.5 )
838- end
841+ @test issocket (controlpath)
842+ test_n_remove_pids (new_pids)
843+ @test :ok == timedwait (()-> ! issocket (controlpath), 10.0 ; pollint= 0.5 )
839844
840845 print (" \n All supported formats for hostname\n " )
841846 h1 = " localhost"
0 commit comments