starlightprivate / flash2

nodejs app
0 stars 0 forks source link

flash2

Docker friendly javascript application with backend and frontend

Badges

Codeship Status for starlightgroup/flash2 bitHound Overall Score bitHound Dev Dependencies bitHound Code Code Climate Test Coverage Issue Count Greenkeeper badge

To feed our sin of pride,

Requirements

  1. Linux (sorry, i have 0 skills with other OSes and cannot assist further)
  2. Nodejs of >=7.5.0
  3. Redis server running with stack settings (localhost:6379 without password)

Or

  1. docker + docker-compose

How to start

With nodejs (>=7.5.0) and redis on local machine:

  1. npm install
  2. npm run-script frontend
  3. npm start
  4. Open [http://localhost:8000/]
  5. Open [http://localhost:8000/tacticalsales/]

With docker and docker-compose installed

  1. Edit /etc/hosts to add flash2.local as alias for localhost.

    [root@ivory vodolaz095]# cat /etc/hosts
    127.0.0.1   localhost localhost.localdomain localhost4 localhost4.localdomain4 flash2.local
    ::1         localhost localhost.localdomain localhost6 localhost6.localdomain6 flash2.local
  1. docker-compose up --build
  2. Open [http://flash2.local]
  3. Open [http://flash2.local/tacticalsales/]

How to build frontend code

Source codes are in frontend directory. Run npm run-script gulp to process them and save output in public directory.

TODO - livereload?

How to run tests

  1. npm run-script eslint (works for backend code mainly)
  2. npm test (unit tests for backend code, supertest and mocha)

How to contribute to this repo

See CONTRIBUTING.md

How to run unit tests using docker-compose


    # docker-compose -f docker-compose.testing.yaml up --build

It have to provide result like this test result