Refactor code into packages
Merge remote-tracking branch 'kraman/refactor' into merge_kraman

Conflicts:
	api/http.go
	dispatcher/dispatcher.go
	gear.go
	gear/ports.go
	gear/templates.go
	jobs/alter_container_state.go
	jobs/build_image.go
	jobs/container_log.go
	jobs/create_container.go
	jobs/environment.go
	jobs/jobs.go
Fix integration tests and travis
Merge pull request #41 from smarterclayton/merge_kraman

Refactor code into packages