sak*_*a73 8 continuous-integration expo github-actions
npm ci这是我在 GitHub 操作文件中运行命令时遇到的问题。
Run npm ci
npm ERR! Error while executing:
npm ERR! /usr/bin/git ls-remote -h -t ssh://git@github.com/------
npm ERR!
npm ERR! Warning: Permanently added the RSA host key for IP address '140.82.113.4' to the list of known hosts.
npm ERR! git@github.com: Permission denied (publickey).
npm ERR! fatal: Could not read from remote repository.
npm ERR!
npm ERR! Please make sure you have the correct access rights
npm ERR! and the repository exists.
npm ERR!
npm ERR! exited with error code: 128
npm ERR! A complete log of this run can be found in:
npm ERR! /home/runner/.npm/_logs/2021-10-19T11_32_39_340Z-debug.log
Run Code Online (Sandbox Code Playgroud)
sak*_*a73 11
经过大量研究,我发现当您通过 Github 帐户使用分叉的 npm 包时会发生这种情况。在管道中,它正在尝试通过 ssh 进行访问。
为此,您需要在eas-pipeline.yml文件中的步骤之后添加一个额外的步骤Checkout。
- name: Checkout
uses: actions/checkout@v2
with:
persist-credentials: false
*******************************************************************************
- name: Reconfigure git to use HTTP authentication
run: >
git config --global url."https://github.com/".insteadOf
ssh://git@github.com/
*******************************************************************************
Run Code Online (Sandbox Code Playgroud)
因为我在 StackOverflow 上找不到任何解决方案,而当我们遇到任何问题时,StackOverflow 是我们的第一个去处。所以,我决定把这个答案写在这里。
这是原始答案:https://github.com/actions/setup-node/issues/214
| 归档时间: |
|
| 查看次数: |
4558 次 |
| 最近记录: |