Thanks for posting!
It sounds like a possible permissions issue. Could you run the following commands in terminal and post the results?
ls -l /Library/FileMaker\ Server/Data/Scripts/<name of bash script>
ls -l <path to test file>/test.txt
Also, is that the exact statement you're running within your script, "touch test.txt"? Try referring to test.txt using the full file path.
Here is the result of the ls -la :
auer01:Scripts serveradmin$ pwd
auer01:Scripts serveradmin$ ls -la
drwxrwxr-x 3 fmserver fmsadmin 102 Feb 14 11:41 .
drwxrwxr-x@ 7 fmserver fmsadmin 238 Feb 4 2010 ..
-rwxrwxrwx@ 1 serveradmin admin 28 Feb 14 11:41 test.sh
did "chmod -x test.sh" and "chmod 777 test.sh" just to be sure
I changed the script to touch /path/file.txt - and it works now - it was a permission issue. By default with just "touch text.txt" it was attempting to create that file at / and permissions wouldn't allow it.
In FMS 10 - what user was it running the script as ??? fmsadmin, right ? Can it be changed ? (I know in FMS 11 we can specify in the scheduler what user to run the script as).
I tried to modify the script to do what it's intended to do - move things around - and again it failed when run from the scheduler, so same permissions issue. Is there anyway to run it with a higher priviledge from the scheduler of FMS 10 ?
touch /Shared\ Items/Fondation/file.txt
mv /Shared\ Items/Fondation/file.txt /Library/WebApps/auerphoto/public/images
Thanks for your help !
There's no way to run a script as a different user with FileMaker Server 10 but setting the appropriate permissions for fmserver on every folder you're touching should work fine.
In regards to the faililng move statement, my guess is that the serveradmin user doesn't have write privileges on /Library/WebApps/auerphoto/public/images.