1
description "Juju API agent"
4
start on runlevel [2345]
5
stop on runlevel [!2345]
7
env JUJU_ZOOKEEPER={{zookeeper}}
9
# Fix for bug 1130681: when the environment sets "juju-origin: lp:juju",
10
# easy_install mucks sys.path and the juju libs are not found, unless we
11
# change to their directory so that it comes first in sys.path.
14
# Use --nodaemon so that upstart can correctly retrieve the process ID.
15
exec /usr/bin/python -m juju.agents.api --nodaemon --port {{port}} \
16
--logfile /var/log/juju/api-agent.log \
17
--session-file /var/run/juju/api-agent.zksession \
18
--secure --keys {{keys}} {{if read_only}} --read-only {{endif}}