SFTP Deployment Failing
We are using the ftp deployment provider but getting errors authenticating to the remote server. I can access the build worker via ssh and run the sftp deployment manually from the build worker using the same credentials with no problems. Our deploy configuration is below. The error we are seeing on the server appears to be "no matching host key type found. Their offer: ssh-rsa,ssh-dss [preauth]"
The server is running Ubuntu 22.04 with software versions OpenSSH_8.9p1 Ubuntu-3ubuntu0.6, OpenSSL 3.0.2 15 Mar 2022
We have tested with both ubuntu-2004 and ubuntu-2204 build worker images
deploy:
provider: FTP
protocol: sftp
host: redacted
username: redacted
password:
secure: redacted
folder: redacted
artifact:
Keyboard shortcuts
Generic
? | 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
Support Staff 1 Posted by Feodor Fitsner on 04 Apr, 2024 03:56 AM
Hi Collin,
It could be the SFTP library used by AppVeyor build agent (SSH.NET) does not support enabled host key types or, perhaps, requires an update. Take a look at its readme to see if key type amongst supported types: https://github.com/sshnet/SSH.NET
If so, you may try writing a simple console app trying to connect to your SFTP server using the latest SSH.NET version.
Alternatively, you can just use
sftp
Linux command as the build runs on Linux, or WinSCP if you deploy from Windows.2 Posted by Collin Newberry on 05 Apr, 2024 01:26 PM
Thank you Feodor, I checked the docs and it looks like there is overlap between the current version of SSH.NET and the OpenSSH server we are running. I will look into using a simple bash script to do the deployment.