Skip to content

getKeyFile error: ssh: no key found #132

Description

@rlintott

I'm using Tekton and trying to scp to a server using the image docker.io/appleboy/drone-scp:latest

  - name: upload-script
    image: docker.io/appleboy/drone-scp:latest #tag: 1.6.1
    script: |

      echo "$(params.SSH_SCRIPT)" > script.sh
      echo "$SSH_PUBLIC_KEY" > ${HOME}/.ssh/id_rsa
      drone-scp --host $(params.HOST) \
        --port $(params.PORT) \
        --username $(params.USERNAME) \
        --key-path "${HOME}/.ssh/id_rsa" \
        --target testing \
        --source script.sh

the ssh key is public. Apparently that might be the issue. Is there a way to connect with a public key? Because the server I want to connect to has the private key
But I am getting this output:

tar all files into /tmp/880393127/dUVpoOUcUS.tar
scp file to server.
2022/01/27 21:05:21 getKeyFile error: ssh: no key found
2022/01/27 21:05:25 error copy file to dest: <ip>, error message: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none password], no supported methods remain
drone-scp error:  error copy file to dest:  <ip>, error message: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none password], no supported methods remain

Thanks

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions