[英]Bitbucket pipeline fail to push to heroku
I do have a react.js app (create-react-app) I setup the file just like explained in the official docs, everything went good but the push failed with this specific line 我确实有一个react.js应用程序(create-react-app)我设置文件就像在官方文档中解释的那样,一切都很顺利但推送失败了这个特定的行
git push https://heroku :$API_KEY@git.heroku.com/$APP_NAME.git HEAD:master
git push https:// heroku :$API_KEY@git.heroku.com/$APP_NAME.git HEAD:master
The bitbucket-pipelines.yml is on the root folder: 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
What I'm doing wrong? 我做错了什么? The goal here is to use the CI on bitbucket platform but also push master commits to heroku repository to automate deploys.
这里的目标是在bitbucket平台上使用CI,但也将master提交推送到heroku存储库以自动化部署。
The error I'm getting is: 我得到的错误是:
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
First, make sure your script does not involve git push git push https://heroku:
. 首先,确保你的脚本不涉及
git push git push https://heroku:
.
It should be git push https://heroku:
... 它应该是
git push https://heroku:
...
Second, as described here , make sure to use your HEROKU_API_KEY, the one returned by heroku authorizations --json
(field " token
") 其次,如此处所述 ,请务必使用您的HEROKU_API_KEY,即
heroku authorizations --json
返回的一个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
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.