Don't use $HOME to find user's directory, some shells don't set it

This commit is contained in:
C. R. Oldham 2015-05-06 14:33:20 -06:00
parent 1b13ec04c2
commit 4ef9e6ba06

View File

@ -529,7 +529,7 @@ def __get_ssh_credentials(vm_):
'ssh_username', vm_, __opts__, default=os.getenv('USER'))
ssh_key = config.get_cloud_config_value(
'ssh_keyfile', vm_, __opts__,
default=os.getenv('HOME') + '/.ssh/google_compute_engine')
default=os.path.expanduser('~/.ssh/google_compute_engine'))
return ssh_user, ssh_key