Comments (6)
My guess would be that there is no benefit of having this in this central action. I've added a note at https://github.com/webfactory/ssh-agent/blob/master/README.md#run-ssh-keyscan-to-add-host-keys-for-additional-hosts.
from ssh-agent.
I don't know about pm2
. Does that SSH into another machine? Does Host key verification failed.
happen there?
from ssh-agent.
Yes it does SSH into the machine the app should be deployed on. The error happens there
from ssh-agent.
Then you need to find a way how to provision your known_hosts
key there. I am afraid this action cannot do this for you.
from ssh-agent.
Ok, thanks for taking the time. I'll try over at pm2 repo to find some answers.
from ssh-agent.
Ok I figured something out. After disabling strict host checking in my pm2 ecosytem file I got this output:
[PM2] Spawning PM2 daemon with pm2_home=/home/runner/.pm2
[PM2] PM2 Successfully daemonized
--> Deploying to production environment
--> on host MY.SERVER
fatal: HEAD does not point to a branch
○ deploying origin/master
○ executing pre-deploy-local
○ hook pre-deploy
Warning: Permanently added '[MY.SERVER]:36077,[45.10.26.70]:36077' (ECDSA) to the list of known hosts.
So it seems the problem was that host that I wanted deploy to (MY.SERVER
) was not in the list of known_hosts
on the GH build instance.
Is that something this action could also take care of? Like it does with adding the private key to the ssh-agent?
The script could do ssh-keyscan -t rsa MY.SERVER | ssh-keygen -lf -
to add the server to known_hosts
file.
from ssh-agent.
Related Issues (20)
- Enable custom github server HOT 1
- Can't get it to work – Permission denied HOT 1
- Update to node20 HOT 2
- Windows workflow fails with "Could not read from remote repository" HOT 5
- `no such identity` on self-hosted Linux Github runner HOT 2
- After update to 0.9.0: The ssh-private-key argument is empty ... HOT 9
- Post cleanup fails HOT 2
- Error: Command failed: ssh-add - HOT 1
- Error: does not match GitHub URL pattern. Not treating it as a GitHub deploy key on version 0.9.0 HOT 8
- changelog out of date HOT 1
- Documentation about how to set up self-hosted runners HOT 4
- When upgrading from 0.7.0 to 0.8.0, functionality breaks HOT 2
- add ssh key for host?
- Is there a way to setup this without having a key specified?
- 'Support for GitHub deploy keys' breaks local CI for repositories which are submodules of other repositories which use ssh-agent with local CI
- The "file" argument must be of type string. Received undefined - in Post job HOT 1
- README needs to be updated (SSH keys should no longer be made in PEM format)
- Host key verification failed on Windows on 0.9.0 HOT 5
- how to use it with ssh keys protected with passwords?
- Cargo Dependencies on Linux Runner HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ssh-agent.