diff --git a/dist/index.js b/dist/index.js index 82a703c..91ecf95 100644 --- a/dist/index.js +++ b/dist/index.js @@ -31084,7 +31084,7 @@ function start_vm(qemu_version, os, cpu, arch, bios, machine, filename, pubkey) qemu_wrapper(qemu_executable, qemu_args, (qemu_process) => { let runScript = core.getInput('run'); fs.writeFileSync('/tmp/run.sh', runScript); - let ssh = spawn('ssh', ['-tt', '-o', 'StrictHostKeyChecking=no', '-p', '2222', '-i', pubkey.split('.')[0], 'root@localhost'],); + let ssh = spawn('ssh', ['-tt', '-o', 'StrictHostKeyChecking=no', '-p', '2222', '-i', pubkey.replace('.pub', ''), 'root@localhost'],); ssh.stdout.pipe(process.stdout); ssh.stderr.pipe(process.stderr); ssh.stdin.write(`chmod +x /tmp/run.sh\n/tmp/run.sh\n`); diff --git a/index.js b/index.js index 361de0f..252f053 100644 --- a/index.js +++ b/index.js @@ -194,7 +194,7 @@ function start_vm(qemu_version, os, cpu, arch, bios, machine, filename, pubkey) qemu_wrapper(qemu_executable, qemu_args, (qemu_process) => { let runScript = core.getInput('run'); fs.writeFileSync('/tmp/run.sh', runScript); - let ssh = spawn('ssh', ['-tt', '-o', 'StrictHostKeyChecking=no', '-p', '2222', '-i', pubkey.split('.')[0], 'root@localhost'],); + let ssh = spawn('ssh', ['-tt', '-o', 'StrictHostKeyChecking=no', '-p', '2222', '-i', pubkey.replace('.pub', ''), 'root@localhost'],); ssh.stdout.pipe(process.stdout); ssh.stderr.pipe(process.stderr); ssh.stdin.write(`chmod +x /tmp/run.sh\n/tmp/run.sh\n`);