def upload_to_host(self, filename, hostname):
result = self._run_command(<EOL>["<STR_LIT>", hostname, filename],<EOL>stderr=open("<STR_LIT>", "<STR_LIT:w>")<EOL>)<EOL>result['<STR_LIT>'] = hostname<EOL>if '<STR_LIT:error>' not in result:<EOL><INDENT>result['<STR_LIT:url>'] = self.parse_output(hostname, result.pop('<STR_LIT>'))<EOL><DEDENT>return result<EOL>
Upload a file to the given host.

        This method relies on 'plowup' being installed on the system.
        If it succeeds, this method returns a dictionary with the host name,
        and the final URL. Otherwise, it returns a dictionary with the
        host name and an error flag.

        :param filename: The filename of the file to upload.
        :type filename: str
        :param hostname: The host you are uploading the file to.
        :type hostname: str
        :returns: Dictionary containing information about upload to host.
        :rtype: dict