There are several reasons why Nginx may serve PHP files as downloads instead of executing them.
This error message can have several causes.
You can use the set_time_limit() function in PHP to increase the maximum execution time of a PHP script.