I tried to connect to ssh with pipelines, but got this error :
Pseudo-terminal will not be allocated because stdin is not a terminal.
ssh_askpass: exec(/usr/bin/ssh-askpass): No such file or directory
Permission denied, please try again.
I used the bitbucket keys, and installed them on my server.
Was wondering if it could from the docker image. I used the default one.
Any suggestion ?
I struggled with this for a day and followed all the comments without it working.
The one thing that eventually worked for me was letting bitbucket create the private and public keys and using those instead of the ones I created myself.
I then added the public key (as it says ) to the server's `~/.ssh/authorized_keys` file (as a new line)
It all then worked.
I could ssh my ubuntu server without any problem after having created a key in bitbucket pipelines as describred in doc.
I use the node:6.9.4 image and simply added
ssh -t firstname.lastname@example.org "cd /var/my/path ; yarn install -prod"
in my pipeline script.
Did you add the target server in known_hosts ?
What is the line in the script that throws the message ?
Thanks for your answer.
I didn't add the target server in known_hosts because bitbucket asks for the key fingerprint of the server. I thought it was sufficient.
But I finally managed to make it work by adding :
- eval `ssh-agent -s` - ssh-add ~/.ssh/id_rsa - ssh-add -l
before the ssh command, if I use a custom made key.
This trick doesn't work for bitbucket keys, but I should try to add this known_hosts file.
Hi everyone, We are looking to learn more about development teams’ workflows and pain points, especially around DevOps, integrations, administration, scale, security, and the related challeng...
Connect with like-minded Atlassian users at free events near you!Find an event
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no Community Events near you at the moment.Host an event
You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events