Friday, 20 November 2015
codeship build error (follow my previous post)
I have another post for explaining how to use codeship with heroku for CIT.
But i have to say that we are using free account from codeship and heroku, so when they got new features to test, they will use our project to test and that will broken our build very badly!!!
yesterday i found an issue:
with the solution and build script from "http://baiduhix.blogspot.co.uk/2015/06/codeship-heroku-cicd-continuously.html" my build run smoothly, but heroku app always down.
And i finally found that, codeship haven't push "/dist" to heroku.
The reason is codeship changed their git push heroku from:
so we have to change the script to:
By default we use the Node.js version set in your package.json or 0.10.25
# You can use nvm to install any Node.js version.
# i.e.: nvm install 0.10.25
# This is to get compass on the server
# rvm use 2.0.0-p195
rvm use ruby-2.1.2
# nvm install 0.10.32
# nvm use 0.10.32
npm install bower -g
# Install grunt-cli for running your tests or other tasks
npm install grunt-cli
#below code are used to remove .gitignore to push output into heroku.
ls -la dist/
rm -f .gitignore
git config --global user.email "firstname.lastname@example.org"
git config --global user.name "herokukiller"
git add --all
git commit -m "remove .gitignore"
export COMMIT_ID=`git rev-parse HEAD`
export CI_COMMIT_ID=`git rev-parse HEAD`