Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Xvfb on Gentoo
XVFB=/usr/bin/Xvfb
XVFBARGS=":100 -screen 0 1600x1200x24 -auth /etc/conf.d/Xvfb.cfg -nolisten tcp"
PIDFILE=/var/run/Xvfb.pid
#!/sbin/runscript
# Copyright 2006 Andreas Bulling
# Distributed under the terms of the GNU General Public License v2
start() {
ebegin "Starting virtual X frame buffer: Xvfb"
start-stop-daemon --start --pidfile $PIDFILE --make-pidfile --background --exec $XVFB -- $XVFBARGS
eend ${?}
}
stop() {
ebegin "Stopping virtual X frame buffer: Xvfb"
start-stop-daemon --stop --pidfile $PIDFILE
eend ${?}
}
# emerge install just what's needed for Xvfb
USE="minimal xvfb -xorg" emerge xorg-server
# create all of the above files in this Gist: /etc/init.d/Xvfb, /etc/conf.d/Xvfb.cfg, /etc/conf.d/Xvfb
chmod +x /etc/init.d/Xvfb
rc-update add Xvfb default
# start Xvfb
/etc/init.d/Xvfb start
@ghost

This comment has been minimized.

Copy link

commented Jan 26, 2018

I know this is old, but would it be okay for me to add this to the Official Gentoo Wiki?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.