Browse files

Updated to use circus

This update includes files and instructions for auto-restarting on AWS
clusters. See README.rst for details. Also note that you will have to
re-run pip install -r prod-reqs.txt
  • Loading branch information...
1 parent 75a018b commit 79425ea4810761d01d646d05a7451199126ec3cb @jrconlin committed Nov 28, 2012
Showing with 36 additions and 9 deletions.
  1. +20 −9 README.rst
  2. +5 −0 circus.ini
  3. +6 −0 crontab.file
  4. +1 −0 prod-reqs.txt
  5. +4 −0 run
29 README.rst
@@ -11,22 +11,21 @@ System Requirements:
Please make sure the following packages are installed on the system:
-mysql #required for
-zmq #
Once those packages are successfully installed:
-$ make build
+ $ make build
This will run the build steps required to get things started.
Please make sure that the build is successful and that all packages are installed.
-$ cp campaign.ini campaign-local.ini
-$ $EDITOR campaign-local.ini
+ $ cp campaign.ini campaign-local.ini
+ $ $EDITOR campaign-local.ini
(It is recommended that you copy campaign.ini to campaign-local.ini and
edit that file. This will prevent accidental updates of the configuration.)
@@ -45,11 +44,20 @@ Running
To run:
-$ bin/pserve campaign-local.ini
+ $ bin/pserve campaign-local.ini
This will start a server listening on the current host at port 8080. You
may change the port in use via the campaign-local.ini configuration file.
+For installation on a stand alone system (e.g. an AWS instance) where you
+may wish the system to restart on reboot, you can easily get started by
+doing the following.
+If necessary, modify crontab.file to reflect correct path. If you already
+have a crontab file, append the contents, else:
+ $ crontab crontab.file
@@ -65,7 +73,7 @@ Once connected, you will be presented with a form. Empty values are considered
Requesting Announcements
An optional GET parameter of "idle" may be passed to indicate the number of
days the platform has been idle.
@@ -77,11 +85,14 @@ where:
Channel for the messages (e.g. 'firefox', 'aurora', 'nightly')
+ Channel version to target
Specific device platform (e.g. 'b2g-utx')
- Channel version to target
+ Optional days that the user agent has been idle.
Returns a JSON object containing
5 circus.ini
@@ -0,0 +1,5 @@
+# We only need circus for the process restart features.
+# TODO: I've seen problems with circusctl restart actually restarting.
+cmd = bin/pserve
+args = campaign-local.ini
6 crontab.file
@@ -0,0 +1,6 @@
+# Many modern crontab installations allow you to specify system events as
+# well as times. See man 5 crontab
+# Please modify the path to fit reality.
+@reboot (cd ~/campaign_manager/;./run;)
1 prod-reqs.txt
@@ -15,6 +15,7 @@ WebOb==1.2.2
4 run
@@ -0,0 +1,4 @@
+#! /bin/sh
+# This file starts a circusd deamon to control a pylons server
+bin/circusd circus.ini

0 comments on commit 79425ea

Please sign in to comment.