2
# This will be run when the service is being torn down, allowing you to disable
4
# For example, if your web app uses a text file to signal to the load balancer
5
# that it is live... you could remove it and sleep for a bit to allow the load
6
# balancer to stop sending traffic.
7
# rm /srv/webroot/server-live.txt && sleep 30
9
BUILDBOT_DIR=`config-get installdir`
12
juju-log "Stopping buildbot in $BUILDBOT_DIR"
14
buildbot stop $BUILDBOT_DIR
15
juju-log "Finished stopping buildbot"
3
# Copyright 2012 Canonical Ltd. This software is licensed under the
4
# GNU Affero General Public License version 3 (see the file LICENSE).
15
log('Stopping buildbot in {}'.format(config['installdir']))
16
run('close-port', '8010/TCP')
18
log('Finished stopping buildbot')
21
if __name__ == '__main__':