.phpを実行する代わりに、ダウンロードしています。.phpを実行する代わりに、Nginxがファイルをダウンロードしています
私はUbuntu 16.04 LTSと/ etc/nginx/sites-available/defaultにphp7を設定しようとしています。
誰でも手助けできますか?
server {
listen 80 default_server;
listen [::]:80 default_server;
root /var/www/html;
index index.php index.html index.htm index.nginx-debian.html;
server_name mydomain.com www.mydomain.com;
return 301 https://$server_name$request_uri;
location/{
try_files $uri $uri/ =404;
}
location ~ \.php$ {
include snippets/fastcgi-php.conf;
include fastcgi_params;
fastcgi_pass unix:/run/php/php7.0-fpm.sock;
}
}
server {
index index.html index.htm index.nginx-debian.html;
# SSL configuration
listen 443 ssl http2 default_server;
listen [::]:443 ssl http2 default_server;
include snippets/ssl-mydomain.com.conf;
include snippets/ssl-params.conf;
location /web {
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $remote_addr;
proxy_set_header Host $host;
proxy_pass http://localhost:32400/web/;
}
}