forked from crosswalk-project/crosswalk
-
Notifications
You must be signed in to change notification settings - Fork 0
Trybot
xingnan edited this page May 27, 2013
·
7 revisions
Github Worker is a standalone server to help sync the github repos and trybot server. You can easily trigger, check and rebuild the patches of the github repos by comments in trybot.
Pulling the status of pull requests Pulling the status of trybot builds
GITHUB <======================================= WORDER ============================================> TRYBOT
| -----------Created/Updated-----------> | |
| <--------Update the dashboard--------- | |
| -------Trigger build by reviewer-----> | |
| | ----------run_trybot_github.sh------------> |
| <--------Update the dashboard--------- | |
| | |
| | <------------Finished the build------------ |
| <--------Update the dashboard--------- | |
| -----------Trigger rebuild------------ | |
| | ----------run_trybot_github.sh------------> |
| | |
- WORKER monitors the status of pull requests in GITHUB repos by Github API
- WORKER monitors the status of TRYBOT by the JSON API provided by http://wrt-buildbot.bj.intel.com/buildbot/json/help
- run_trybot_github.sh is a wrap script to run depot_tools/trychange.py to create the build in trybot.
- The dashboard in GITHUB repo actually is a comment sent by the WORKDER, which can be updated by reviewers and WORKER.
- Reviewers can select the bots they want to try.
- Reviewers can select the bots to rebuild the patches.
- Install node and MongoDB
- Check out codes from powerbuilder.sh.intel.com:/home/www-data/git-repos/github-worker.git
- Configure in the github-worker/src/lib/common.js
- Start /your/dir/to/mongoDB/bin/mongod by default setting
- cp github-worker/src/run_trybot_github.sh to /your/dir/to/build-infrastructure/
- Run node index.js in github-worker/src/
- src/index.js Interface to start the WORDER.
- lib/daemon.js Main implementation of WORKER. Main loop in the file, call github API to fetch the events/status of pull requests; Handle the state machine of pull requests; etc.
- lib/common.js Configs in this file.
- lib/command.js Interface to run the local command.
- lib/github.js Interface to interact with the trybot.
- lib/dashboard.js Interface to interact with the github comments.
- lib/db.js Connect the mondoDB.