Backbone/Marionette/Gulp
$ npm install --global gulp
$ npm install
Start a local dev environment:
$ gulp
Generate a production build:
$ gulp production
Download [settings.json](link to settings.json file goes here) and place in root directory.
The following command will deploy to AWS S3:
$ gulp deploy --[env]
This boilerplate assumes you've created a settings.json
file in the project root. This file should be (git)ignored as it contains sensitive information, i.e. AWS keys, etc. When deployment is finished, a Slack hook will be triggered in a channel of your choice.
--dev
or--development
--qa
--stage
or--staging
--prod
or--production
One of these arguments is required to successfully deploy files to S3, i.e gulp deploy --staging
.
{
"default": {
"aws": {
"accessKeyId": "xxx",
"secretAccessKey": "xxx",
"basePath": "xxx",
"bucket": "bucketname"
},
"slack": {
"hook_url": "https://hooks.slack.com/services/xxx/xxx/xxx",
"username": "username",
"message": "New build up on: "
}
}
}
Individual envs can have their own settings by adding a corresponding 'env': {...}
to the settings file, only those settings which are different from default need to be set.