This is a seed project to build a production ready website containing
- AngularJS
- RequireJS
- Node.JS
- LESS
- Bootstrap
- CoffeeScript
- jQuery
- SEO ( using phantomjs )
- Versioned/minified/compressed static content and cdn deployment
- Easy production deployment
Please have the following before building
Optional tools that make the process smoother
- Sublime Text. Sublime project included.
- Heroku account w/ toolbelt installed
- AWS S3 account
git clone https://github.com/solomon23/solomon-angular-node-seed.git
npm install
grunt server
Note: If you copy the contents of the pull be sure to copy the .hidden files as well
Navigate to http://localhost:3000
and confirm site is functioning
grunt build
cd ./build
git init
add .
git commit -am "new"
heroku create
heroku config:add BUILDPACK_URL=https://github.com/ddollar/heroku-buildpack-multi.git
git push heroku master
heroku ps:scale web=1
heroku config:set NODE_ENV=production
heroku config:set PATH="/usr/local/bin:/usr/bin:/bin:/app/vendor/phantomjs/bin"
heroku open
A browser should open with your new site functioning
Create a file called ~/aws.json
in your home folder:
{
"test":{
"key": "...",
"secret": "...",
"bucket": "..."
}
}
Modify the config file ./server/config.coffee
prod =
cdn: "http://s3.amazonaws.com/xxx"
grunt s3:prod
Subsequent deploys to heroku can use the same site
grunt build
grunt deploy
or manually with
grunt build
cd ./build
git add .
git commit -am "New"
git push heroku master