-
-
Notifications
You must be signed in to change notification settings - Fork 74
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Key not used during SSH handshake #51
Comments
I seem to be experiencing this issue as well.. |
I would set the file permissions 0600 and give that a try. openssh is strict about the key security. If that still does not work, I would also assume a bug. |
Please set file permission as |
@webpolis Any updates? |
hi @appleboy ,
my yml for docker swarm is
permission is set to 400
|
@fredix I will try your config. |
Is there any update on this issue?? |
Hi @appleboy , I have the same issue, any updates ?? |
@dev-drprasad Could you help try to add ssh key using drone secret? |
Dear all, BUT, I solved the problem only by upgrading the drone from 0.7 to 0.8. |
@chrisliuqq It is working on drone 0.5, 0.6, 0.7 and 0.8 version with secrets in drone. maybe I should try it out for the |
This was awhile ago but I believe I experienced this issue whilst trying to mount an ssh key to my drone server's ~/.ssh directory (Which is a big no-no). I would recommend creating a brand new drone container and make sure you aren't mounting anything funky to the drone server and then adding the key via secrets as @appleboy suggests. |
I have enabled the But I find a solution: Mount private key to the plugin's container instead of drone agent. pipeline: pipeline:
ssh:
image: appleboy/drone-ssh
host: xxxxx.com
username: deploy
volumes:
- /root/drone_rsa:/root/ssh/drone_rsa
key_path: /root/ssh/drone_rsa
script:
- echo "test ssh" That works! Of course, enabled the |
@harryxu @fredix Already updated readme. See the updates: https://github.com/appleboy/drone-ssh#mount-key-from-file-path |
I gave up using secrets... :-( :-( It simply didn't work. I'd set a secret in the GUI, via the drone CLI. But this buried on the bottom of the front door worked
|
I tried
And cutting and pasting the contents of /vagrant/.vagrant/machines/toolchain/virtualbox/private_key into the Drone Secret gui for a
then using a pipeline like so
And I could always from the command line:
|
So how do I generate the drone_rsa key in the drone container? |
@harryxu Do we need to generate an ssh key inside the container? where does |
@itsnauman Use ssh-keygen command. |
Inside the container? or do I mount a volume with the SSH key |
@itsnauman You can generate ssh key on host os, and mount it to container. |
The following drone.yml is failing with
(Drone 1.6.1) |
Syntax changed https://docker-runner.docs.drone.io/configuration/volumes/host/ which turns the above to:
|
I gave up using secret...and using volumes and key_path works! my pipeline |
I have my key_path set and properly mounted, but it seems it's not even used during SSH handshake:
This is how the pipeline looks like:
And my docker-compose.yml:
Of course, the .key file is present:
The text was updated successfully, but these errors were encountered: