This commit is contained in:
Matthias Pigulla 2021-03-02 16:11:15 +00:00
parent a4b2891e37
commit c77dd5afd7
3 changed files with 3 additions and 5 deletions

View file

@ -44,7 +44,6 @@ jobs:
deployment_keys_demo:
env:
GIT_SSH_COMMAND: ssh -v
DISPLAY: fake
strategy:
fail-fast: false
matrix:
@ -59,9 +58,8 @@ jobs:
${{ secrets.MPDUDE_TEST_1_DEPLOY_KEY }}
${{ secrets.MPDUDE_TEST_2_DEPLOY_KEY }}
- run: |
cat ~/.ssh/config
git clone git@github.com:mpdude/test-2.git test-2-git
# cat ~/.ssh/config
# ls -alh ~/.ssh
# git clone https://github.com/mpdude/test-1.git test-1-http
# git clone git@github.com:mpdude/test-1.git test-1-git

2
dist/index.js vendored
View file

@ -221,11 +221,11 @@ try {
// On Windows, IdentitiesOnly=yes will ignore keys from the agent, but send explicit keys first; so use "no" (https://github.com/PowerShell/Win32-OpenSSH/issues/1550)
let identitiesOnly = isWindows ? 'no' : 'yes';
// Use IdentitiesOnly=no due to https://github.com/PowerShell/Win32-OpenSSH/issues/1550
let sshConfig = `\nHost key-${keyNumber}\n`
+ ` HostName github.com\n`
+ ` User git\n`
+ ` IdentitiesOnly ${identitiesOnly}\n`
+ ` AddKeysToAgent yes\n`
+ ` IdentityFile ${keyFile}\n`;
fs.appendFileSync(`${homeSsh}/config`, sshConfig);

View file

@ -104,11 +104,11 @@ try {
// On Windows, IdentitiesOnly=yes will ignore keys from the agent, but send explicit keys first; so use "no" (https://github.com/PowerShell/Win32-OpenSSH/issues/1550)
let identitiesOnly = isWindows ? 'no' : 'yes';
// Use IdentitiesOnly=no due to https://github.com/PowerShell/Win32-OpenSSH/issues/1550
let sshConfig = `\nHost key-${keyNumber}\n`
+ ` HostName github.com\n`
+ ` User git\n`
+ ` IdentitiesOnly ${identitiesOnly}\n`
+ ` AddKeysToAgent yes\n`
+ ` IdentityFile ${keyFile}\n`;
fs.appendFileSync(`${homeSsh}/config`, sshConfig);