aboutsummaryrefslogtreecommitdiffstats
path: root/main/qemu/qemu-guest-agent.initd
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2013-02-18 08:12:51 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2013-02-18 08:12:51 +0000
commit7107d7e96fbcfe1a3b6bee91dd1b385ef37bd4fc (patch)
tree57d604dd8873e90d5103091ebba0310258f61f67 /main/qemu/qemu-guest-agent.initd
parente01307048f5535dac57faa4c7f6727bfd857ca56 (diff)
downloadaports-7107d7e96fbcfe1a3b6bee91dd1b385ef37bd4fc.tar.bz2
aports-7107d7e96fbcfe1a3b6bee91dd1b385ef37bd4fc.tar.xz
main/qemu: add guest-agent subpackage
Diffstat (limited to 'main/qemu/qemu-guest-agent.initd')
-rw-r--r--main/qemu/qemu-guest-agent.initd25
1 files changed, 25 insertions, 0 deletions
diff --git a/main/qemu/qemu-guest-agent.initd b/main/qemu/qemu-guest-agent.initd
new file mode 100644
index 0000000000..83876308ae
--- /dev/null
+++ b/main/qemu/qemu-guest-agent.initd
@@ -0,0 +1,25 @@
+#!/sbin/runscript
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/app-emulation/qemu-guest-agent/files/qemu-ga.init,v 1.2 2012/10/30 21:12:20 cardoe Exp $
+
+start() {
+ GA_METHOD=${GA_METHOD:-virtio-serial}
+ GA_PATH=${GA_PATH:-/dev/virtio-ports/org.qemu.guest_agent.0}
+
+ ebegin "Starting QEMU Guest Agent"
+
+ start-stop-daemon --start --pidfile /var/run/qemu-ga.pid \
+ --exec /usr/bin/qemu-ga -- -m ${GA_METHOD} -p ${GA_PATH} \
+ -l /var/log/qemu-ga.log -d
+
+ eend $?
+}
+
+stop() {
+ ebegin "Stopping QEMU Guest Agent"
+
+ start-stop-daemon --stop --pidfile /var/run/qemu-ga.pid
+
+ eend $?
+}