def upload_file(sftp, local_filepath, remote_filepath):
    """Upload a file to the server.

    :param sftp: Paramiko SFTPClient connection to a server.
    :type sftp: SFTPClient
    :param local_filepath: Absoluate path to file to be uploaded.
    :type local_filepath: str
    :param remote_filepath: Absoluate path to server destination.
    :type remote_filepath: str
    :returns: Indicates whether upload was successful.
    :rtype: bool
    """
    try:
        sftp.put(local_filepath, remote_filepath)
        result = True
    except:
        print(
            'Problems encountered with the specified local or destination directories.'
            )
        result = False
    return result
