hghazal / frontend-react-webapp-template

Docker React Redux Universal web app template that easily runs on Google's container engine through Kubernetes

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Roller's Frontend Template

***

Stack:

Release Workflow:

  • Create a feature branch and a pull request
  • Get the code reviewed
  • Merge code into master
  • CircleCI runs the CI process which includes

Local Dev workflow

  • Clone the repo locally
  • Install dependencies
$ npm install
  • Run the app server
$ npm run dev
  • Write tests and run tests before pushing
$ npm run test
  • Ensure that you're following the coding guidelines
$ npm run lint
  • Regurally check that you're running the latest dependencies
$ npm run deps

Manually releasing code:

  • Publish new image to the registry
$ ./deploy/publish.sh
  • Run the rolling update command to release the code, the command takes an optional argument that lets you add a tag the Kubernetes controller's name. It's required if you're releasing code with the same git SHA1 hash.
$ ./deploy/rolling-update.sh [label]

Current Issues:

  • Releasing code in a rolling update on Kubernetes might break the user experience. Consider the situation when a user sends a request to load a page and that page requests another resource. Kubernetes Replication Controller (RC) will use round robin to route the traffic, thus requesting a resource that is either no longer on the new docker image or hasn't made it to the new docker instance.

    Potential Solution: Use version numbers in the url of the resource and distribute the assets on a CDN.

About

Docker React Redux Universal web app template that easily runs on Google's container engine through Kubernetes


Languages

Language:CSS 79.6%Language:JavaScript 18.6%Language:Shell 1.8%