bansho/README.rst

129 lines
2.3 KiB
ReStructuredText
Raw Normal View History

2015-04-24 10:44:56 -04:00
======
Bansho
======
2014-12-17 15:39:53 -05:00
Web Interface for Surveil
* Bug tracker: https://launchpad.net/bansho
* Open Gerrit changesets: https://review.openstack.org/#/q/status:open+bansho,n,z
* Surveil: https://github.com/stackforge/surveil
2014-12-17 15:39:53 -05:00
.. image:: https://github.com/stackforge/surveil-specs/raw/master/bansho.png
:alt: Bansho interface picture
2015-04-30 15:13:12 -04:00
Production
==========
2014-12-17 15:39:53 -05:00
::
2015-04-30 15:13:12 -04:00
sudo apt-get install docker.io
git clone https://github.com/stackforge/bansho
2015-04-24 10:44:56 -04:00
cd bansho
2015-04-30 15:13:12 -04:00
make build
make production
2014-12-17 15:58:15 -05:00
2015-04-30 15:13:12 -04:00
You can alternatively forge a Docker command to select your port.
2014-12-17 15:58:15 -05:00
2015-01-23 15:56:20 -05:00
2015-04-30 15:13:12 -04:00
Development
===========
2014-12-17 15:58:15 -05:00
2015-04-30 15:13:12 -04:00
Clone project :
::
git clone https://github.com/stackforge/bansho
2015-04-30 15:13:12 -04:00
cd bansho
2015-04-30 15:13:12 -04:00
Install development dependencies :
2015-02-20 16:26:45 -05:00
::
2015-05-04 10:13:30 -04:00
sudo apt-get install npm nodejs-legacy ruby docker.io
npm install grunt-cli bower
2015-04-30 15:13:12 -04:00
npm install
bower install
2015-05-04 10:13:30 -04:00
gem install sass
2015-04-30 15:13:12 -04:00
make build
2015-05-04 10:13:30 -04:00
Start the Docker container (be sure to have a surveil container available at this link: https://github.com/stackforge/surveil )
::
2015-04-30 15:13:12 -04:00
make daemon
2015-04-21 16:27:15 -04:00
2015-04-30 15:13:12 -04:00
2015-01-23 11:40:11 -05:00
If you wish to develop in a docker container, here is how to proceed (assuming
you already have docker installed) :
2015-01-22 17:34:35 -05:00
::
2015-04-30 15:13:12 -04:00
curl http://localhost:8888/
2015-03-04 16:29:05 -05:00
2015-04-30 15:13:12 -04:00
To only compile sass files to css run :
2015-03-04 16:29:05 -05:00
2015-04-30 15:13:12 -04:00
::
grunt sass
2015-03-04 16:29:05 -05:00
2015-01-16 17:25:19 -05:00
Coding style
2015-03-04 16:29:05 -05:00
============
2015-01-16 17:25:19 -05:00
This project conforms to JSLint coding style (http://github.com/douglascrockford/JSLint).
Run the linter as follows:
::
grunt jshint
2015-01-16 17:25:19 -05:00
Tests
=====
AngularJS comes with Karma which is an automatic unit test runner.
While running, Karma automatically executes the tests when any js file changes.
To launch Karma :
::
npm test
2014-12-17 15:58:15 -05:00
Launch
======
::
npm start
2014-12-17 15:39:53 -05:00
2015-04-24 10:44:56 -04:00
Now, go on http://127.0.0.1:8000/app/
Contributing
============
To contribute to this project, please fork the repo. Then do your commits (branch as you will)
and then open a pull-request to this repo's master branch.
::
<fork this repo on github>
2015-04-24 10:44:56 -04:00
git clone your-repo/bansho
git checkout -b dev-new-feature-xx
git commit ...
git push origin dev-new-feature-xx
<You can now open your pull-request to this repo's master>
Good practices before opening a pull request:
- Run tests with `npm test`
- Lint your .js files with `grunt jslint`
2015-04-24 10:44:56 -04:00
- Make sure your directives are prefixed with `bansho`
- Make sure your controllers are suffixed with `Ctrl`
- Resolve merge conflicts locally