Home

Awesome

Autolander

Build Status Dependency Status devDependency Status

Description:

Autolander is a tool which manages continuous integration workflows between Bugzilla and Github. Autolander has several features including:

Validations:

Basic Repository Integration

Autolander will check if you have either an autolander.json or a taskgraph.json in the project root in order to determine whether or not to run tests on treeherder. If you have neither of these then autolander will simply merge code to master when the autoland keyword is added.

Enabling Autolander for additional repositories

We don't yet have a UI in place to easily do this, so for the time being, Autolander needs a few things in place to function:

Autolander Component Interaction

Autolander interacts between several components, some of which are:

Development

Configuration

Create configuration if needed. Copy the template config file to the environment (development or production), and fill in the keys. An example config/production.js file already exists which uses environment defines - this is useful for deploying to a server which already has these defined. Ask me if you need development keys.

cp config/development.js.tpl config/development.js

Running tests

End-to-end integration tests which test against real instances of bugzilla, pulse, github, taskcluster and treeherder. Running tests is the recommended way to develop for autolander.

# Run all tests for the project:
npm test

# Run a single test:
./test/runone.sh test/some_test.js

# Each test will automatically spin up the worker and web servers by default.
# It can be useful to run these on your own for debugging purposes.
# To do this, first spin up the web and worker instances.
DEBUG=* ./bin/web
DEBUG=* ./bin/worker

# Run tests with NO_SERVER=1 if you do this.
NO_SERVER=1 npm test

Local Environment

Ensure that the :autolander (https://github.com/autolander) github account has push access to your repository.

Using ngrok for a tunnel to localhost is the easiest way to develop. Fork your repository of choice. Once you have a tunnel setup, add a webhook to your repository that points to https://<id>.ngrok.com/github.

./ngrok 80

Start the server.

// You need to start both the web interface, and the listener.
node ./bin/web
node ./bin/worker

// Or start with debug logging:
DEBUG=* node --harmony ./bin/web
DEBUG=* node --harmony ./bin/worker

// Start for production and debugging
DEBUG=* node --harmony ./bin/web production
DEBUG=* node --harmony ./bin/worker production