There is a website with a button, cliking the button should lunch a bash script that suppose to unmount a directory. The button calls functions.inc
php script with this function:
function sftmz_release_s3test_connections($bucket_name){
if($bucket_name == 's3test'){
drupal_set_message('Check mount status ! - released?');
$cmd = '/var/www/html/company/sites/default/modules/rp_minisite/admin/script.sh';
exec($cmd);
}
}
My problem is: When im in the shell and running the command:
/var/www/html/company/sites/default/modules/rp_minisite/admin/script.sh
It works fine.
When I click the button, the test appears, but it does not run the script. How can i view logs ? Can i print logs to shell ? i cant since its being activated using a button on html...
I assume this is permission issues?