mirror of
https://github.com/wassname/ray.git
synced 2026-08-13 12:30:18 +08:00
Create ~/.ssh if it doesn't already exist (#9880)
This commit is contained in:
@@ -289,6 +289,10 @@ def _configure_key_pair(config):
|
||||
|
||||
ec2 = _resource("ec2", config)
|
||||
|
||||
# Writing the new ssh key to the filesystem fails if the ~/.ssh
|
||||
# directory doesn't already exist.
|
||||
os.makedirs(os.path.expanduser("~/.ssh"), exist_ok=True)
|
||||
|
||||
# Try a few times to get or create a good key pair.
|
||||
MAX_NUM_KEYS = 30
|
||||
for i in range(MAX_NUM_KEYS):
|
||||
|
||||
Reference in New Issue
Block a user