~cpick/upstart-cookbook/workers

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
Overview
--------

The Upstart Cookbook is written in ReStructuredText a tagless markup
language [1]_. You may recognize the syntax from Pythons Sphinx
documentation [2]_.

Building
--------

Prerequisite
~~~~~~~~~~~~

To build the document in HTML format, first ensure that you have the
docutils package installed. On an Ubuntu system, this can be achieved by
running::

  sudo apt-get install python-docutils

Further, since the doc now auto-includes the upstart-events(7) man page,
you'll need to either be running Ubuntu, or have a local copy of
upstart-events.7. At the the time of writing, the latest version can be
found here:

  http://bazaar.launchpad.net/~ubuntu-branches/ubuntu/precise/upstart/precise/files/head:/debian/manpages/

If you're running on Ubuntu, that man page will be installed on your
system and the build will use *that version of the man page*. However,
if you wish to reference a newer version of the file set the
`UPSTART_EVENTS_FILE` variable (see below for an example).

To install the required tools to convert the troff+tbl to ASCII on an
Ubuntu system, run::

  sudo apt-get install doclifter xsltproc tidy elinks

Bazaar Keywords Plugin
~~~~~~~~~~~~~~~~~~~~~~

To install the Bazaar keyword plugin::

  mkdir -p ~/.bazaar/plugins && cd ~/.bazaar/plugins
  bzr get lp:bzr-keywords keywords
  cat >>~/.bazaar/rules<<EOT
  [name *.rst]
  keywords = on
  EOT

HTML
~~~~

Run::

  make OUTDIR=/tmp

If you don't have the Bazaar keyword plugin::

  make OUTDIR=/tmp NOBZR=y

If you want to reference a different version of upstart-events(7)::

  # XXX: Note: don't put `upstart-events.7` in /tmp as the build
  # XXX: will delete XXX: it!
  make OUTDIR=/tmp UPSTART_EVENTS_FILE=$HOME/upstart-events.7

PDF
~~~

Run::

  make OUTDIR=/tmp pdf

Again, without the Bazaar keyword plugin::

  make OUTDIR=/tmp NOBZR=y pdf

References
----------

.. [1] http://docutils.sourceforge.net/docs/user/rst/quickstart.html
       http://docutils.sourceforge.net/docs/user/rst/quickref.html
.. [2] http://sphinx.pocoo.org/