Commit de6505b7 by George Song Committed by George Song

Use systemd to manage xvfb

parent 5c4bbb49
......@@ -64,9 +64,11 @@
- assert:
that: "phantomjs.stat.exists"
- name: create xvfb upstart script
template: src=xvfb.conf.j2 dest=/etc/init/xvfb.conf owner=root group=root
- name: create xvfb systemd service
template: src=xvfb.service.j2 dest=/etc/systemd/system/xvfb.service owner=root group=root
- name: register xvfb systemd service
shell: systemctl enable /etc/systemd/system/xvfb.service
- name: start xvfb
shell: start xvfb
ignore_errors: yes
service: name=xvfb state=started
description "Xvfb X Server"
start on (net-device-up and local-filesystems and runlevel [2345])
stop on runlevel [016]
exec /usr/bin/Xvfb {{ browser_xvfb_display }} -screen 0 1024x768x24
respawn
respawn limit 15 5
[Unit]
Description=X Virtual Frame Buffer Service
After=network.target
[Service]
ExecStart=/usr/bin/Xvfb {{ browser_xvfb_display }} -screen 0 1024x768x24
[Install]
WantedBy=multi-user.target
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment