Reputation: 401
I am trying to use the Bitbucket Pipelines feature to deploy a node.js project to Heroku. The script(taken from documentation) is:
image: node:6
clone:
depth: full
pipelines:
default:
- step:
script:
- npm install
- git push https://heroku:[email protected]/$HEROKU_APP_NAME.git master
I have set up the enviorment variables for the API key and project name however I am getting the following error:
+ git push https://heroku:[email protected]/$HEROKU_APP_NAME.git master
fatal: remote part of refspec is not a valid name in .git
What am I doing wrong here?
Upvotes: 4
Views: 3406
Reputation: 41
This will work, but in my experience so far the token expires every 8 hours so you'll have to find a different solution.
Upvotes: 1
Reputation: 401
As it turned out when I copied the app_name environment variable I copied it with a trailing space which was the error.
Upvotes: 3