2
# Copyright 2009 Canonical Ltd.
4
# This file is part of desktopcouch.
6
# desktopcouch is free software: you can redistribute it and/or modify
7
# it under the terms of the GNU Lesser General Public License version 3
8
# as published by the Free Software Foundation.
10
# desktopcouch is distributed in the hope that it will be useful,
11
# but WITHOUT ANY WARRANTY; without even the implied warranty of
12
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13
# GNU Lesser General Public License for more details.
15
# You should have received a copy of the GNU Lesser General Public License
16
# along with desktopcouch. If not, see <http://www.gnu.org/licenses/>.
18
# Author: Stuart Langridge <stuart.langridge@canonical.com>
20
Stop local CouchDB server.
22
import subprocess, sys
25
local_exec = local_files.COUCH_EXEC_COMMAND + ["-k"]
27
retcode = subprocess.call(local_exec, shell=False)
29
print >> sys.stderr, "Child was terminated by signal", -retcode
31
print >> sys.stderr, "Child returned", retcode
33
print >> sys.stderr, "Execution failed: %s: %s" % (e, local_exec)