This is the CONTRIBUTING.md for our project. Great to have you here. Have a look at our README.md if you're unfamiliar with Project Monitor.
Product Manager: Mike McCormick
The google group for Project Monitor is projectmonitor_pivotallabs.
The public Tracker project for ProjectMonitor is here.
There are two distinct layers to Project Monitor:
- the front end which polls the back end for updates and
- the back end which polls CI builds and receives webhook updates.
The front end is written in Backbone/CoffeeScript. Individual Backbone models are responsible for polling the database. Backbone views update when the model is updated. The back end receives updates through a REST/json interface, or it uses delayed_job to poll CI instances.
The public Tracker project for ProjectMonitor is here.
To run tests, run:
rake setup
rake spec
To run Jasmine tests, run this once when setting up the project or if you haven't consistently been running guard:
rake jasmine:compile_coffeescript
To keep your jasmine tests current, run:
guard
Install phantomjs if needed:
brew install phantomjs
Then, to run Jasmine tests from the command line, run:
RAILS_ENV=test bundle exec rake spec:javascript
To run Jasmine tests from the browser, with a rails server running, visit http://localhost:3000/specs
See the jasmine-rails documentation for more details.
Vagrant automatically sets up virtual machines to run Jenkins. First install VirtualBox. Then run the following commands to set it up.
vagrant up
Useful commands
vagrant ssh
vagrant halt
vagrant provision
vagrant destroy #If you just halt, it will not rebuild everything from scratch
Once the VM has started, services will be available at 192.168.33.10
.
To run a local development server and worker, run:
foreman start
Project Monitor has been moved under the "Pivotal" organization. In order to have push privileges to the repo, you will need to request that your GitHub account is added as a collaborator.
- If you're testing anything with CoffeeScript, you probably want to run
guard
so that the files are re-compiled each time. - Are the workers running? Have you checked the worker log in log/delayed_job.log?
- You can run
rake projectmonitor:fetch_statuses
to force update the builds.
If you encounter any bugs, feel free to file an issue in Github or contact our Product Manager: Graham Siener.
CI for ProjectMonitor is here, and it's aggregated at ci.pivotallabs.com (that's an instance of ProjectMonitor, of course).
Please consider this a living document. When you've finished your work please take a minute to think of the developers who will follow in your footsteps. Is there anything missing from this document that you'd wished you'd known before you started coding?