How can I force one window to always remain at the back of the window stack? I want to run FireFox pinned to the desktop and prevent other windows from ever ending up behind it.
Sparky1's questions
Is it possible to open a browser window at a given size/location on screen via a shell script ?
I've seen examples of launching Firefox, setting the window size via command line. I've also seen it written up as non working as a Firefox bug. Are there any alternative browsers that will do this that run on 10.04?
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?
I want to add the Apache user (www-data
) to the audio
group. I've read the man page for useradd
, but I'm not having any luck. I'm running xubuntu 11.10. Here's what I'm doing:
$ sudo useradd -G audio www-data
useradd: user 'www-data' already exists
If I leave out the -G
option, bash, prints the help info for useradd
:
$ sudo useradd audio www-data
Usage: useradd [options] LOGIN
Options: -b, --base-dir BASE_DIR base directory for the home directory...
It's not clear to me from the man page what options I should use to make this work.
I'm running xubuntu 11.10. From php, I'm calling a shell that exports the display and then calls wmctrl. Every time I call wmctrl, I see an error "Cannot open display".
I call my shell from php:
$output = shell_exec('/var/www/wmctrl.sh');
My hostname is steven-Z-CLASS
Here is my shell script:
#!/bin/bash
export DISPLAY=steven-Z-CLASS:0.0
echo $DISPLAY
wmctrl -m
When I run this, I see the echoed display value in my php page:
steven-Z-CLASS:0.0
However, wmctl does not run. I see this error in the apache log:
Cannot open display.
Any ideas why wmctrl can't open the display?
I'm running ubuntu 11.10. I want to be able to call a shell script from php and run that script as root. When my php attempts to call the shell script as root --like this:
$output = shell_exec('sudo /var/www/my_script.sh')
I get this error in the apache log:
sudo: no tty present and no askpass program specified
I've changed the owner of the php script to root:root. I've added this line to sudoers:
www-data ALL = NOPASSWD:/var/www/my_script.php
I realize that I'm supposed to comment out this line in sudoers:
Defaults requiretty
However, there's no such line in my sudoers file. What do I need to do to get past this error?
Can anyone point me to a good tutorial on installing a root certificate on Ubuntu?
I've been provided with a .crt
file. I gather that need to create a directory at /usr/share/ca-certificates/newdomain.org
and place the .crt
in that directory. Beyond that I'm not sure how to proceed.