From 3dff1910ac1c6869ee06b1337af8bea121505937 Mon Sep 17 00:00:00 2001 From: Bertrand Jacquin Date: Sat, 15 Aug 2015 23:00:12 +0100 Subject: factory-default/x11-base/xorg-server: Add Xvfb init script --- .../x11-base/xorg-server/etc/init.d/Xvfb | 24 ++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100755 factory-default/x11-base/xorg-server/etc/init.d/Xvfb (limited to 'factory-default') diff --git a/factory-default/x11-base/xorg-server/etc/init.d/Xvfb b/factory-default/x11-base/xorg-server/etc/init.d/Xvfb new file mode 100755 index 00000000..67f4fad9 --- /dev/null +++ b/factory-default/x11-base/xorg-server/etc/init.d/Xvfb @@ -0,0 +1,24 @@ +#!/sbin/runscript +# Copyright 1999-2015 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +PIDFILE="/run/${RC_SVCNAME}.pid" +XVFB=/usr/bin/Xvfb +XVFBARGS=":0 -screen 0 1600x1200x24" +USER=nobody + +start() { + ebegin "Starting virtual X frame buffer: Xvfb" + start-stop-daemon --start \ + --pidfile "${PIDFILE}" --make-pidfile \ + --user "${USER}" --background \ + --exec "${XVFB}" -- ${XVFBARGS} + eend $? +} + +stop() { + ebegin "Stopping virtual X frame buffer: Xvfb" + start-stop-daemon --stop --pidfile "${PIDFILE}" + eend $? +} -- cgit v1.2.3