<div dir="ltr">I am hoping to get some help here with building custom PHP to manage a 'wake up call' system.<div><br></div><div>I have the script where the user can set the schedule for an extension wake up call.</div><div><br></div><div>It appears to write to the /var/spool/asterisk/outgoing/ directory.</div><div><br></div><div>My two issues:</div><div><br></div><div>1 - when the files do get moved over to outgoing/ directory via a cron job, the permissions show "-rw-r--r-- 1 apache apache 100 Jan  1  2016 5680a312a28b2.call" and the calls get sent when the date comes to pass. But my question is, if I mv 3 files from my php script,  'll /var/spool/asterisk/outgoing/' shows 'total 12' when there are only three files in the directory. What does total mean? Is my perl script doing something that I am not aware of and really there are 12 files overlapped or something funky?<br></div><div><br></div><div>--- cron job perl script</div><div><div>my @list = glob("/tmp/*.call");</div><div>for( 0 .. $#list )</div><div>{</div><div>        system "mv $list[$_] /var/spool/asterisk/outgoing/";</div><div>}</div><div>-------------------------------</div></div><div><br></div><div>2 - I would like to view and delete call files but as it currently stands, php gets a permission denied.</div><div>obviously php is running as apache and the outgoing/ directory is asterisk:asterisk but the call files are apache:apache. My question is, what is the best way, without risking security, to allow php to list and delete the files? I know my scripts themselves work because when I chown apache:apache /var/spool/asterisk/outgoing the script works. I have seen front ends work with all the same permissions on outgoing/ and the files but I dont know how they are able to read/delete the files for monitor/ which is the same as the outgoing/ directory.</div><div><br></div><div>Thanks for your help in advance all!</div><div>--Eric</div><div><br></div></div>