Your suggestion is good but it's working when I run Your script manually (sh /root/script.sh). When I try to make Cron do it nothing happens.
* * * * * sh /root/script.sh > /dev/null
I have also tried using full path:
* * * * * /bin/sh /root/script.sh > /dev/null
Here's a script from /var/scripts which Your script should execute:
useradd -d /home/someuser -s /bin/bash -m -g someuser someuser
echo "someuser:somepassword" | chpasswd
It's also working when I run it manually.
All that might seem a little strange because I haven't fully described what I'd like to do. The test server runs Apache (default installation) with php. A php script generates shell scripts in /var/scripts/ with information provided in the form. You know the rest. I'm close but I'm missing something here because Cron doesn't execute them.