sftp with key authentication on linux image

Christoffer's Avatar


18 Apr, 2019 10:13 AM


I have read the previous threads stating that you do not support ssh key authentication for sftp since it is using a .NET implementation. However, on the Linux images it should be possible to use this. I have noticed that you use lftp, which seem to have a workaround by not passing the password at all.


  1. 1 Posted by Christoffer on 18 Apr, 2019 11:41 AM

    Christoffer's Avatar

    I currently have this solved by running the following:

        - lftp -e 'set sftp:connect-program "ssh -a -x -i sshkey";set cmd:trace yes;set cmd:verbose yes;mkdir -f /home/user/deploy;put -O /home/user/deploy /home/appveyor/projects/project.jar;put -O /home/ec2-user/deploy /home/appveyor/projects/project.yml;bye' -u user,xxx sftp://host

    This means risking breaking changes by not using the default deploy provider though.

Reply to this discussion

Internal reply

Formatting help / Preview (switch to plain text) No formatting (switch to Markdown)

Attaching KB article:


Attached Files

You can attach files up to 10MB

If you don't have an account yet, we need to confirm you're human and not a machine trying to post spam.

Keyboard shortcuts


? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac