When it comes to receiving/sending files to/from a remote SFTP server from your integration; be it – BizTalk Server/Logic Apps/other middleware’s out in the world, an adapter/connector is available with the product which can be used without writing a single line of code. Some SFTP providers often restrict access to their system using their firewall and they hence have to whitelist our outgoing IP address. This seems fairly easy task, if your on-premise/cloud middleware application has a single/couple of outgoing IP address’s. If for e.g. you use Logic Apps, there is a big list of outgoing IP address and runtime IP address that needs to be whitelisted by the SFTP vendor. The vendor could agree to whitelist, but by doing that they are giving blanket access to applications which use Logic Apps. Although there is a second layer of security, where the authentication is controlled by either username/password or ssh. But, still it defeats the point of having firewall rules in the first place.
So, in those situations, a tiny little SFTP library running as a docker instance could save us. As of now, it is not possible to have this docker instance running in Azure, as the container group uses a different IP address for outbound traffic. Below excerpt is from MS documentation.
AWS offers a cost effective way for deploying docker instances and having a single outgoing ip address.
Now, this SFTP library is built using node.js express. I have published the code to github.
I have added swagger to the api which should be helpful for consuming the service.