I have a shell script 'vlc.sh' that plays a video using vlc:
#!/bin/bash vlc /home/sparky/sample.mp4
When I run this script from my login, I get audio + video.
When I call this script from the Apache user (via php), I get only video. The Apache error log complains about audio:
[0x96053ec] pulse audio output error: cannot connect to server: Connection refused ALSA lib confmisc.c:768:(parse_card) cannot find card '0' ALSA lib conf.c:4184:(_snd_config_evaluate) function snd_func_card_driver returned error: No such file or directory oss audio output error: cannot open audio device (/dev/dsp)
I've tried adding the apache user to the audio, pulse, pulse-access, and admin groups. But I've have had no luck. I'm running xubuntu 11.10. What should I try next?