开发者

403 Forbidden error using cron and curl

I have an fcron job to run a php script in the background and the output is written into a file. However the only outout I get is a 403 forbiden error. My fcron is working but it does not have access to my localhost. How can I make sure that fcron job has access to localhost? I am the owner of localhost i.e the folder where my localhost is(I know it isnt safe but this is production purposes).entry in fcrontab:

0开发者_StackOverflow中文版 * * * * curl "http://localhost/main/sendmail.php"


Got it. Create the fcrontab as super user aka su. SU has permission to everything.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜