-
Notifications
You must be signed in to change notification settings - Fork 149
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
Permission denied (publickey). #143
Comments
@LeonardoFurtado I had the same error, and it appears that this is the actual issue:
I would double check that your private key secret has a newline character at the end of the file, because for some reason libcrypto requires it to be a "valid format" |
There is no newline character at the end of my file :/ |
run this in your server: This is a frustrating issue, even if you are deploying locally, you still need to add the public key to authorized_keys, otherwise you won't be able to login using your private key (and of course, you might need to configure some settings in sshd_config as well). |
I have similar issue and problem on my side seems to be that the key file created by ssh-deploy has Windows line endings. I am able to reproduce issue using cmd line and the file produced by this action. After having run it through |
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days. |
Adding comment to remove stale label, issue has suggested solution and is waiting for maintainer approval. |
Don't know why, but the private key secret requires a new line character at the end (Just hit the enter key). |
This PR #156 should solve the issue |
Given that #156 was merged in v4.1.10, this issue is probably fixed. @LeonardoFurtado can you corroborate it and close the issue? |
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days. |
Added public key to authorized_keys and added a new line to private key. The issue still persists. |
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days. |
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days. |
What solved it for me was to generate a new key as per: Initially I was using my standard key, which had a passphrase, which caused issues. |
Mine doesn't have any paraphrases, yet the issue persists. |
Can you try |
Did you resolved the Issue, |
I solved the problem smoothly this way, so if anyone else has this problem, try using my method. |
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days. |
From my situation, consider these details. It helped me and I really hope that helps you a lot. Pay attention to SSH_PRIVATE_KEY configuration. It's written clearly in README. As it can tell, the public key part should be added to the Further more, notice
Pay Attention once again that copy all contents of this file including comments like Hope it can help you guys. |
I'm trying to use this action, but the job is completed and the files are not uploaded.
My steps.
I create a new EC2 instance, downloaded de PEM that I generated when created the instance.
I've alocated a Elastic IP to my instance, So i'm using it on REMOTE_HOST secret
Added the default ubuntu name on REMOTE_USER secret
Copied the content of my .pem key on SSH_PRIVATE_KEY secret
I dont created a REMOTE_TARGET.
After execute the job I've received the following warnings and the folder was not upload to my ec2 instance.
This is my workflow.yml
The text was updated successfully, but these errors were encountered: