Python script through php on Amazon EC2

后端 未结 2 1657
小鲜肉
小鲜肉 2021-01-21 20:57

I am trying to run a simple python script through php on Amazon EC2 instance.

The file is working fine on terminal i.e am getting the output. But when am trying the same

2条回答
  •  执笔经年
    2021-01-21 20:58

    I guess first place one should look is the apache error log at. You don't want to enable sudo. Please consider checking the error log of apache to understand what is the underlying problem at:

    /var/log/apache or similar directory

    Please review these posts for a better solution and review of the problem:

    How to execute shell_exec on EC2 Linux

    https://forums.aws.amazon.com/thread.jspa?messageID=692394

    php shell_exec() command is not working

提交回复
热议问题