Installing Moodle 3.8.2 on Azure WebApps

Installing Moodle 3.8.2 on Azure WebApps

by Muhammad Sohaib -
Number of replies: 9

Been trying to set up a PaaS based Moodle instance on Azure. The backend database resides on a MySQL server instance on Azure, and trying to set up Moodle on WebApps. 


Using the SSH access that I have, I can download and unzip Moodle directory, run the installer from the /wwwroot/admin/cli. The installer works perfectly well, the backend database gets populated. I get a message that installation is successful. 


As soon as i go and try accessing the URL, i get an error which quotes: "error/ An error occured whilst communicating with the server". That is it, no details, nothing.


Been trying to fix this for a while now, can anyone help in debugging? The only access I have on the WebApp is to read write etc., to the wwwroot folder. Moodledata resides one level above this, and I made sure all users have the access to read/write to that folder as well. 


The OS on the Azure WebApp is Debian, MySQL is 5.7.27. Config is attached. 

Average of ratings: -
In reply to Muhammad Sohaib

Re: Installing Moodle 3.8.2 on Azure WebApps

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers
Check the web server error log
In reply to Howard Miller

Re: Installing Moodle 3.8.2 on Azure WebApps

by Muhammad Sohaib -
The only entry in the log created on access is the following:

020-04-16T10:23:07.302255367Z: [ERROR] 172.16.2.1 - - [16/Apr/2020:10:23:07 +0000] "GET / HTTP/1.1" 503 985 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/80.0.3987.163 Safari/537.36"
In reply to Muhammad Sohaib

Re: Installing Moodle 3.8.2 on Azure WebApps

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers
That's the access log, not the error log.
In reply to Howard Miller

Re: Installing Moodle 3.8.2 on Azure WebApps

by Muhammad Sohaib -
Apparent'y i don't have access to view that. The log stream on Azure App service is only providing this log. The log is not being written to the disk either, with a /dev/stdout next to the file.
In reply to Muhammad Sohaib

Re: Installing Moodle 3.8.2 on Azure WebApps

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers
In reply to Howard Miller

Re: Installing Moodle 3.8.2 on Azure WebApps

by Muhammad Sohaib -
Yeah that did not work - i had already gone through all the documentation on logs by that point - log analytics did not give me anything. Anyway, deleted that experiment and would go with IAAS based architecture.
In reply to Muhammad Sohaib

Re: Installing Moodle 3.8.2 on Azure WebApps

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers
Do you actually need the additional complication? You could just spin up an instance of "normal" Ubuntu or CentOS and install Moodle and its dependencies.
In reply to Howard Miller

Re: Installing Moodle 3.8.2 on Azure WebApps

by Muhammad Sohaib -
I was looking at scenarios where i can automate the scaling operations of the Moodle instance. While IAAS seems the way to go, but setting up multiple frontends with a load balancer in front and then dealing with NFS mounts for shared data, etc takes a lot. And then you have to ensure your frontends don't choke.

If i use VMSS for the frontends, i have to be able to write a script that automates all the deployment on new VMs as they are provisioned and scaled. App service would save infinite time and has availability and scale built in, Azure files would act as shared data mount,etc.