def get_upload_pipeline(in_fd, out_fd, rate_limit=None,<EOL>gpg_key=None, lzop=True):
commands = []<EOL>if rate_limit is not None:<EOL><INDENT>commands.append(PipeViewerRateLimitFilter(rate_limit))<EOL><DEDENT>if lzop:<EOL><INDENT>commands.append(LZOCompressionFilter())<EOL><DEDENT>if gpg_key is not None:<EOL><INDENT>commands.append(GPGEncryptionFilter(gpg_key))<EOL><DEDENT>return Pipeline(commands, in_fd, out_fd)<EOL>
Create a UNIX pipeline to process a file for uploading.
        (Compress, and optionally encrypt)