diff options
-rwxr-xr-x | factory-default/x11-base/xorg-server/etc/init.d/Xvfb | 24 |
1 files changed, 24 insertions, 0 deletions
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 $? +} |