hx-markterry opened a new issue #16323: URL: https://github.com/apache/airflow/issues/16323
With the SSH hook you can specify a private key as a string using the `private_key` param: https://github.com/apache/airflow/blob/main/airflow/providers/ssh/hooks/ssh.py#L138 With the SFTP hook you can only specify a private key path using the `private_key` param: https://github.com/apache/airflow/blob/main/airflow/providers/sftp/hooks/sftp.py#L108 This means that you can not provide a private key string to a SFTP connection, only a path to a file. As the SFTP hook already has the SSH hook as a base class, then changing the `private_key` param to mean a string rather than a file, and using the `key_file` like the SSH hook does, would allow the SFTP hook to support private key strings and files, and would reduce some code in the SFTP hook. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: [email protected]
