4 git reactjs bitbucket-pipelines
我确实有一个react.js应用程序(create-react-app)我设置了文件,就像官方文档中解释的那样,一切都很顺利,但推送失败了这一特定行
git Push https://heroku :$API_KEY@git.heroku.com/$APP_NAME.git HEAD:master
bitbucket-pipelines.yml 位于根文件夹中:
image: node:6
clone:
depth: full
pipelines:
default:
- step:
script:
- npm install
- npm test
- git push git push https://heroku:$API_KEY@git.heroku.com/$APP_NAME.git HEAD:master
Run Code Online (Sandbox Code Playgroud)
我做错了什么?这里的目标是在 bitbucket 平台上使用 CI,同时还将主提交推送到 heroku 存储库以自动部署。
我收到的错误是:
remote: ! WARNING:
remote: ! Do not authenticate with username and password using git.
remote: ! Run `heroku login` to update your credentials, then retry the git command.
remote: ! See documentation for details: https://devcenter.heroku.com/articles/git#http-git-authentication
fatal: Authentication failed for 'https://heroku
Run Code Online (Sandbox Code Playgroud)
首先,确保您的脚本不涉及git push git push https://heroku:.
它应该是git push https://heroku:...
其次,如此处所述,请确保使用您的 HEROKU_API_KEY,即heroku authorizations --json(字段“ token”)返回的密钥
image: node:6
clone:
depth: full
pipelines:
default:
- step:
script:
- npm install
- npm test
- git push https://heroku:$HEROKU_API_KEY@git.heroku.com/$HEROKU_APP_NAME.git HEAD:master
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
1341 次 |
| 最近记录: |