Hi All,
website: https://demo.lms.cool/
Getting the "ERR_TOO_MANY_REDIRECTS" and frontpage keeps redirecting to login/index.php .
The last change I did was to enable SSL with Letsencrypt. It was working fine since then. It has stopped working since maybe couple weeks.
Server is Debian
Moodle version is 3.9.1 hosted on Nginx
I have attempted admin/index.php uncomment trick, no luck
I have tried emptying/deleting cache, localcache, session folders in moodledata, no luck
here is the content of config.php
<?php // Moodle configuration file
unset($CFG);
global $CFG;
$CFG = new stdClass();
$CFG->dbtype = 'sqlsrv';
$CFG->dblibrary = 'native';
$CFG->dbhost = '';
$CFG->dbname = '';
$CFG->dbuser = '';
$CFG->dbpass = '';
$CFG->prefix = 'mdl_';
$CFG->dboptions = array (
'dbpersist' => 0,
'dbport' => '',
'dbsocket' => '',
);
$CFG->wwwroot = 'https://demo.lms.cool';
$CFG->dataroot = '/var/www/moodledata_demo';
$CFG->admin = '';
$CFG->directorypermissions = 0777;
require_once(__DIR__ . '/lib/setup.php');
// There is no php closing tag in this file,
// it is intentional because it prevents trailing whitespace problems!
Here is nginx file in sites-available:
server {
root /var/www/demo;
index index.php index.html index.htm;
server_name demo.lms.cool;
location / {
try_files $uri $uri/ =404;
}
location ~ [^/]\.php(/|$) {
fastcgi_split_path_info ^(.+\.php)(/.+)$;
fastcgi_index index.php;
fastcgi_pass unix:/var/run/php/php7.3-fpm.sock;
include fastcgi_params;
fastcgi_param PATH_INFO $fastcgi_path_info;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
}
listen [::]:443 ssl ipv6only=on; # managed by Certbot
listen 443 ssl; # managed by Certbot
ssl_certificate ; # managed by Certbot
ssl_certificate_key; # managed by Certbot
include ; # managed by Certbot
ssl_dhparam ; # managed by Certbot
}
server {
if ($host = demo.lms.cool) {
return 301 https://$host$request_uri;
} # managed by Certbot
listen 80;
listen [::]:80;
server_name demo.lms.cool;
return 404; # managed by Certbot
}
Any help would be much appreciated.