1#!/bin/sh 2# 3# Starts pulseaudio. 4# 5 6. /etc/profile.d/xdg.sh 7start() { 8 printf "Starting pulseaudio: " 9 umask 077 10 PULSE_HOME=/userdata/.pulse /usr/bin/pulseaudio & 11# --system \ 12# --daemonize \ 13# --disallow-module-loading \ 14# --disallow-exit \ 15# --exit-idle-time=-1 \ 16# --use-pid-file \ 17# --disable-shm 18 echo "OK" 19} 20stop() { 21 printf "Stopping pulseaudio: " 22 PULSE_RUNTIME_PATH=/var/run/pulse /usr/bin/pulseaudio --kill 23 echo "OK" 24} 25restart() { 26 stop 27 start 28} 29 30case "$1" in 31 start) 32 start 33 ;; 34 stop) 35 stop 36 ;; 37 restart|reload) 38 restart 39 ;; 40 *) 41 echo "Usage: $0 {start|stop|restart}" 42 exit 1 43esac 44 45exit $? 46 47