saveriogzz opened a new issue #20144: URL: https://github.com/apache/airflow/issues/20144
### Apache Airflow Provider(s) sftp ### Versions of Apache Airflow Providers apache-airflow-providers-sftp==2.2.0 ### Apache Airflow version 2.2.2 (latest released) ### Operating System Ubuntu 20.04.3 LTS ### Deployment Docker-Compose ### Deployment details _No response_ ### What happened When instantiating an SFTPHook in order to create a connection to an sftp server, I noticed that if I was passing the parameter `ssh_conn_id`, the hook was trying to connect to `localhost`, whereas if I am passing `ftp_conn_id`, I obtain the desired connection. https://github.com/apache/airflow/blob/35be8bdee0cdd3e5c73270b0b65e0552fb9d9946/airflow/providers/sftp/hooks/sftp.py#L67-L69 ### What you expected to happen I would expect to be able to instantiate an sftp conection using the parameter `ssh_conn_id` instead of `ftp_conn_id`. ### How to reproduce _No response_ ### Anything else _No response_ ### Are you willing to submit PR? - [X] Yes I am willing to submit a PR! ### Code of Conduct - [X] I agree to follow this project's [Code of Conduct](https://github.com/apache/airflow/blob/main/CODE_OF_CONDUCT.md) -- 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. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
