Git Product home page Git Product logo

baker's Introduction

#Tasty web Apps with the Baker

Baker is an opinionated web application metaframework that helps you build great web applications. Baker is based on Grunt.js, Backbone.js and Marionette.

Baker is made and heavily used by people from The Bakery

A few things Baker does for you

  • keeps your javascript neat and sane with jshint
  • turns your SASS into CSS
  • gives you js modular goodness with require.js
  • tests your application with karma
  • manages third party dependencies with bower
  • automatically reloads your browser when your code changes
  • deploys your application straight to Amazon S3
  • manages development, staging and production settings

###Bootstrap your project

npm install -g grunt-cli bower 
  • Grab the latest baker release here

  • Install development dependencies for the Baker, do the following

npm install 
  • Provide your AWS credentials
touch aws.json

Your aws.json file should have the following content

{
	"AWSAccessKeyId": "YOUR-AWS-ACCESS-KEY",
	"AWSSecretKey": "YOUR-AWS-SECRET-KEY",
	"AWSRegion" : "AWS-REGION-WHERE-YOUR-BUCKET-IS",
	"stagingBucket": "NAME-OF-YOUR-STAGING-BUCKET",
	"productionBucket": "NAME-OF-YOUR-PRODUCTION-BUCKET"
}
  • Ask baker to get all third party libraries
grunt init

###Run the app (http://localhost:9001)

grunt 

###Manage settings

app/scripts/settings contains a collection of settings modules used in your application

app/scripts/settings/base.js - common settings reused in all the environments
app/scripts/settings/settings.js - local development settings
app/scripts/settings/stage.js - staging settings
app/scripts/settings/prod.js - production settings

###Test

grunt test

###Build

Baker supports 2 types of builds: staging and production

grunt staging-build
grunt production-build

after successful build dist folder will contain your application

###S3 deploy

Amazon S3 is a great place to keep your web application. Refer to this excellent article for more details. We also recommend you set a policy on your static hosting bucket to keep all your static content publicly available automagically

{
	"Version": "2008-10-17",
	"Statement": [
		{
			"Sid": "AllowPublicRead",
			"Effect": "Allow",
			"Principal": {
				"AWS": "*"
			},
			"Action": "s3:GetObject",
			"Resource": "arn:aws:s3:::NAME-OF-YOUR-BUCKET/*"
		}
	]
}

You can deploy both staging and production versions of your app using Baker

grunt stage
grunt deploy

##Problems/Questions/Suggestions

Say hi

===

Happy baking!

baker's People

Contributors

callmephilip avatar markdowney avatar

Watchers

James Cloos avatar Chris Hill avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.