Skip to content
This repository has been archived by the owner on Apr 5, 2018. It is now read-only.

Plugin Squirrel

mheffner edited this page Jan 11, 2012 · 1 revision

Squirrel Plugin

Squirrel is a continuous integration plugin.

Shipping

Squirrel provides a number of standard continuous integration shipping commands to a chat room and converts those commands to a canonical argument list. It will then invoke a shipping command with this argument list and track the success/failure of the shipping command.

Squirrel expects the shipping command to support the following usage:

$ shipcmd [options] commands

Where options are defined as:

  • --application <appname>

This defines the application name to ship.

  • --environment <environment>

This defines the environment to ship. Squirrel supports two environments: staging and production.

  • --branch <branchname>

This specifies the GIT branch or tag to ship.

The supported commands are:

  • deploy: Ship the branch to the application and restart it. (main ship command)
  • environ: Refresh the application configuration and restart it.
  • migrate: Run the migrations for the application.
  • maintenance on|off: Enable or disable maintenance mode.
  • revision: Output the Git SHA of the deployed code.

Commands

> ship <app> [staging|production]

  Ships 'master' to <app> with environment staging or production.

> ship <branch> to <app> [staging|production]

  Ships <branch> to <app> with environment staging or production.

> ship <app> environ [staging|production]

  Ships the latest app environment to <app> and restarts the app.

> ship <app> migrate [staging|production]

  Runs the migration for the specified <app> using the previously
  deployed code.

> ship <app> maintenance:(on|off) [staging|production]

  Put the application into maintenance mode (maintenance:on) or
  disable maintenance mode (maintenance:off) for <app>.

> ship <app> revision [staging|production]

  Show the deployed revision.

Configuration

  • squirrel.apps

This should be set to a list of applications that squirrel can ship. For example: ['api', 'railsux'].

  • squirrel.cmd

This should be set to the executable command that is invoked to perform a ship action. For example: "/path/to/shipit.sh".

  • squirrel.environ

This should be set to any additional environment variables that should be passed to the ship command. For example: {'MYVAR' => 'MYVAL'}.

Clone this wiki locally