[英]Install an npm module from a private GitHub repository using GitHub Actions
[英]AWS Beanstalk Install Private Github Module via NPM Results In Authentication Issue
我需要通過npm在AWS Beanstalk實例上安裝私有github模塊。
我正在使用Github個人訪問令牌來通過github進行身份驗證並訪問存儲庫。
我的package.json
列出了這樣的依賴關系:
"privatepackage": "git+https://jaf91ja9jasflkjasf98109asf10asdf:x-oauth-basic@github.com/user123/privatepackage.git"
但是,在Beanstalk上,部署時出現以下錯誤:
npm ERR! node v0.12.2
npm ERR! npm v2.7.4
npm ERR! code 128
npm ERR! Command failed: git clone --template=/tmp/.npm/_git-remotes/_templates --mirror git@github.com...
npm ERR! Cloning into bare repository '/tmp/.npm/_git-remotes/git-github-com...
npm ERR! Host key verification failed.
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.
我認為您在機器上缺少ssh鍵,並在github上添加了它。
請查看generate-ssh-keys ,它可以幫助您解決此問題。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.