codeigniter4 with nginx ssl not work - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: CodeIgniter 4 (https://forum.codeigniter.com/forumdisplay.php?fid=28) +--- Forum: CodeIgniter 4 Support (https://forum.codeigniter.com/forumdisplay.php?fid=30) +--- Thread: codeigniter4 with nginx ssl not work (/showthread.php?tid=74576) |
codeigniter4 with nginx ssl not work - JerryCode - 10-10-2019 I use the nginx config in codeigniter3,it works。 but in codeigniter4 not work Code: server return 500 error when not use ssl, Code: server also return error I changed permissions but didn't solve the problem Code: chown -R www:www /home/wwwroot/ci400rc21 The logs: Code: 2019/10/12 14:47:59 [crit] 11053#0: *29 connect() to unix:/tmp/php-fpm.sock failed (2: No such file or directory) while connecting to upstream, client: *.*.*.*, server: www.domain.com, request: "GET / HTTP/2.0", upstream: "fastcgi://unix:/tmp/php-fpm.sock:", host: "www.domain.com" Finally I found the problem, because of the index.php in /public, So in nginx fastcgi.conf fastcgi_param PHP_ADMIN_VALUE "open_basedir=$document_root/:/tmp/:/proc/";must be deleted or modified Like this: Code: # fastcgi_param PHP_ADMIN_VALUE "open_basedir=$document_root/:/tmp/:/proc/"; Or Code: fastcgi_param PHP_ADMIN_VALUE "open_basedir=/home/…/:/tmp/:/proc/"; RE: codeigniter4 with nginx ssl not work - kilishan - 10-10-2019 Check server logs. What's the error it's returning? RE: codeigniter4 with nginx ssl not work - JerryCode - 10-12-2019 (10-10-2019, 08:02 PM)kilishan Wrote: Check server logs. What's the error it's returning? The logs: Code: 2019/10/12 14:47:59 [crit] 11053#0: *29 connect() to unix:/tmp/php-fpm.sock failed (2: No such file or directory) while connecting to upstream, client: *.*.*.*, server: www.domain.com, request: "GET / HTTP/2.0", upstream: "fastcgi://unix:/tmp/php-fpm.sock:", host: "www.domain.com" RE: codeigniter4 with nginx ssl not work - titounnes - 10-12-2019 (10-12-2019, 12:14 AM)JerryCode Wrote:repair your nginx configuration. Your probem not related to Codeigniter.You must verivy location/path of php-fpm.sock file(10-10-2019, 08:02 PM)kilishan Wrote: Check server logs. What's the error it's returning? |