Quantcast
Channel: Active questions tagged ubuntu - Stack Overflow
Viewing all articles
Browse latest Browse all 6025

ssh no key found when used with appleboy ssh actions in Github actions for Ubuntu

$
0
0

I am working on my cicd flow with Github actions, and deploying a docker containers on Ubuntu server. Original server authentication was with password. I later added SSH keys generated using PuttyGen on windows, and enabled SSH authentication on Ubuntu. I am able to login using SSH key using putty, so SSH key auth is working fine.

However, when I try to deploy using Github actions using appleboy/ssh-action it fails with an error message

ssh.ParsePrivateKey: ssh: no key foundssh: handshake failed: ssh: unable to authenticate, attempted methods [none], no supported methods remain

Here is the step using appleboy

name: Deploy project on Ubuntu        uses: appleboy/ssh-action@v1.0.3        with:          host: ${{secrets.SSH_HOST}}          port: ${{secrets.SSH_PORT}}          username: ${{secrets.SSH_USERNAME}}          key: ${{secrets.SSH_KEY}}

I verified the key exists in secrets with correct name, and it works when I test it to copy files to the ubuntu server. But when using appleboy it doesn't work.

What could be wrong? Should I need to change the key format or something else is wrong?


Viewing all articles
Browse latest Browse all 6025

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>