def put_file(self, client, source_file):
try:<EOL><INDENT>file_name = os.path.basename(source_file)<EOL>ipa_utils.put_file(client, source_file, file_name)<EOL><DEDENT>except Exception as error:<EOL><INDENT>raise IpaCloudException(<EOL>'<STR_LIT>'.format(<EOL>source_file, error<EOL>)<EOL>)<EOL><DEDENT>else:<EOL><INDENT>return file_name<EOL><DEDENT>
Put file on instance in default SSH directory.