totem / dashboard-v2

Totem v2 dashboard
MIT License
2 stars 1 forks source link

Totem v2 dashboard

Build Status

Setup

You need Node.js 6.9.x installed (use nvm).

Once node is running, you will need Gulp and Bower installed globally to run the project

$ npm install -g gulp bower

Install dependencies:

$ git clone git@github.com:totem/dashboard-v2.git
$ cd dashboard-v2
$ npm install
$ bower install

Build

$ gulp build

This will generate the dist folder that is served in production.

Run

Running requires having the environment variable TOTEM_DASHBOARD_CONFIG set.

Development

$ gulp

Run the app locally in development mode at http://localhost:3000.

Production

$ gulp serve:dist

Run the app in "production" mode locally at http://localhost:3000.

$ docker build -t totem-dashboard:local .
$ docker run -Pit totem-dashboard:local

Run the app in Docker which mirrors production better than the previous command. This requires that Boot2Docker is installed and running.

Test

Unit

$ gulp test

Run unit tests

$ gulp test:auto

When running site in development mode, watch JS files and run unit tests on file change.

End-to-End

$ gulp protractor:src

Run e2e tests against source files

$ gulp protractor:dist

Run tests against generated dist files (production mode)

Deploy

This app is deployed automatically via Totem. (Note: This will be bundled with Totem provisioner in future.)