Moodle + Office 365: Better together


Completing the DNS registrations



Download 345.09 Kb.
Page7/13
Date29.07.2017
Size345.09 Kb.
#24227
1   2   3   4   5   6   7   8   9   10   ...   13

25.Completing the DNS registrations


In order to access your Moodle platform with a domain name other than the one supplied by default by Microsoft Azure (for example m2o-contoso123svc.cloudapp.net in our illustration), you must own an Internet domain name.

For the purpose of this illustration, we have already acquired the public domain name contoso123.fr, which is used for our entire test lab environment.

On the administration page of your Internet domain, add a CNAME (Alias) type record so that a name of your choosing points to your Moodle site.

In our example, we want our Moodle site to be accessible at the address https://o2m.contoso123.fr.

To do this, we have to create a CNAME record in our domain contoso123.fr with the following information:


  • Host: o2m

Points to: m2o-contoso123svc.cloudapp.net

Log onto the Microsoft Azure Management portal to find out the domain name of your Azure platform. Once connected to the portal, go to the Cloud service that hosts your Moodle platform.

At the bottom of the Cloud service dashboard page, you will find the DNS name of the service that can be accessed over the Internet. This is the name that points to the public IP address allocated to your Cloud service by Microsoft Azure.


Setting up the Moodle platform


Your Azure subscription should now be ready to install the Moodle platform at this stage.

This section describes in sequence the setup of:



  • The Apache server required by Moodle,

  • The MySQL server,

  • Moodle itself,

  • The Office 365 integration plugins for Moodle.

26.Setting up the Moodle server


This section assumes that the provided script New-MoodleEnvironment.ps1 has already been executed with the suggested parameters configured. If this is not already the case, see section § Provisioning an Azure environment.

27.Setting up the Apache HTTP server


To setup the Apache HTTP server, proceed with the following steps:

  1. Log onto the Moodle server using the SSH client of your choice (for example, the PuTTY42) client:

  • Host name: m2o-contoso123svc.cloudapp.net

  • Port: 49909



  1. Enter the following user name and password when invited to do so by the server:

  • User name: "moodleadmin"

  • Password: "Contoso123! "

  1. Switch to thesuper user (root) mode with the following command:


moodleadmin@m2o-moodle:~$ sudo –s


  1. Update the packages of the Linux distribution.


root@m2o-moodle:~$ apt-get update


  1. Install the Apache HTTP server


root@m2o-moodle:~$ apt-get install apache2
Note Version 2.4.10 of the Apache HTTP server is installed with this Linux distribution.

28.Setting up the PHP script language and its extensions


To now setup the PHP script language and its extensions, proceed with the following steps:

  1. From the previous SSH connection, install the PHP script language with the following command:


root@m2o-moodle:~$ apt-get install php5
Note Version 5.5.12 of the PHP script language is installed with this Linux distribution.

  1. Install the PHP cURL extension.


root@m2o-moodle:~$ apt-get install php5-curl
Note The PHP cURL extension facilitates communications with many servers using numerous protocols and allows data to be exchanged between Moodle platforms over the MNet network43.

  1. Install the PHP XML -RPC extension.


root@m2o-moodle:~$ apt-get install xmlrpc
Note The PHP XML-RPC extension allows procedure calls to be made on a remote computer.

  1. Install the PHP GD extension.


root@m2o-moodle:~$ apt-get install php5-gd
Note The PHP GD extension is used to create and handle various image formats.

  1. Install the PHP INTL extension.


root@m2o-moodle:~$ apt-get install php5-intl
Note The PHP INTL extension is used to internationalize PHP scripts, and in particular the numbers, dates and times.

  1. Install the PHP OPcache extension.


root@m2o-moodle:~$ apt-get install php5-opcache
Note The OPcache extension improves the performance of PHP by storing the bytecode of the precompiled scripts in shared memory. The installation of this extension is not compulsory, but is strongly recommended by Moodle44.

  1. Install the PHP LDAP extension.


root@m2o-moodle:~$ apt-get install php5-ldap
Note The PHP LDAP extension activates the integration of the LDAP protocol by PHP. LDAP is a communications protocol used to interrogate and modify directory services.

  1. Install the PHP MySQL extension.


root@m2o-moodle:~$ apt-get install php5-mysql
Note The PHP MySQL extension allows for connections to MySQL databases from PHP scripts.

29.Setting up the additional packages required by Moodle


To install the additional packages required by Moodle, proceed with the following steps:

  1. From the previous SSH connection, install TeX Live.


root@m2o-moodle:~$ apt-get install texlive
Note TeX Live provides a LaTeX environment. LaTeX is a system used to create documents and mathematical equations. It is widely used in scientific circles. LaTeX is required by Moodle's standard document creation plugins.

  1. Install Aspell and its English dictionaries.


root@m2o-moodle:~$ apt-get install aspell

root@m2o-moodle:~$ apt-get install aspell-us
Note Aspell is a spell checker required by Moodle's standard document creation plugins. The required English libraries can be found here: http://ftp.gnu.org/gnu/aspell/dict/en/.

  1. Install NTP.


root@m2o-moodle:~$ apt-get install ntp
Note NTP (Network Time Protocol) is a protocol that synchronizes the local clock in a computer with a reference time over a computer network.

  1. Install Sendmail.


root@m2o-moodle:~$ apt-get install sendmail
Note Sendmail is used to send and receive e-mail.

30.Setting up Moodle from the server


It is also possible to install Moodle directly, in the same way as we installed the HTTP server, by executing the following two commands. But this option is not recommended in so far as, in this case, we cannot control the versions of Moodle (e.g., 2.7 vs. 2.8) and SQL (e.g., MySQL vs. PostgreSQL) that are installed. The versions depend on the chosen Linux distribution.
root@m2o-moodle:~$ cd /var/www/html

root@m2o-moodle:/var/www/html$ apt-get install moodle
We are rather going to install Moodle using the versions available on the official Moodle web site45.

To do that, proceed with the following steps:



  1. Still from the same SSH connection, create the directory src.


root@m2o-moodle:~$ mkdir /src

root@m2o-moodle:~$ cd /src
Note Moodle will be downloaded into this directory in the next step.

  1. Download version 2.7 of Moodle in tgz format.


root@m2o-moodle:/src$ wget https://download.moodle.org/download.php/direct/stable28/moodle-latest-27.tgz
Note At the time of writing, the most recent version of Moodle was version 2.8, which was first released on November 10, 2014. Version 2.7 was first released in May 12, 2014. We have chosen to install version 2.7 of Moodle, because it is an LTS version (Long-Term Support), which means that it will be maintained by Moodle for 3 years, instead of 18 months for regular versions. Moreover, not all the plugins developed by the Moodle community are compatible with version 2.8 of Moodle.

Note The links used to download the latest version of Moodle and the versions of Moodle that are still maintained are respectively available on the Latest Release46 and Other supported releases47 pages of the official Moodle site (see the link behind the button Download tgz).

  1. Extract the Moodle files from the archive.


root@m2o-moodle:/src$ tar -xzf moodle-latest-27.tgz


  1. Move the Moodle directories to a directory that is accessible on the web.


root@m2o-moodle:/src$ mv moodle /var/www/moodle

31.Creating the moodledata directory


moodledata is the directory where Moodle stores the files created or downloaded from the platform. All the content created by users will be stored in this directory, and in particular the courses, documents, images and videos hosted on the platform.

To create this directory, proceed with the following steps:



  1. Still from the same SSH connection, create a secure directory called moodledata.


root@m2o-moodle:~$ mkdir /var/moodledata
Note For security reasons, the moodledata directory must not be directly accessible from the web. Therefore, it must not be created in the directory /var/www/.
Note moodledata is the default name of this directory, but it can be renamed.

  1. Authorize the HTTP server to use the moodledata directory.


root@m2o-moodle:~$ chown www-data:www-data -R /var/moodledata

root@m2o-moodle:~$ chmod g+rws -R /var/moodledata
Note Depending on the Linux distribution in use, the Apache user and the default Apache group can be called www-data, nobody or apache.

Note The command chown (change owner) is used to change the owner of the directory, while the command chmod (change mode) changes the privileges of the directory. At this point, we add (+) read (r) and write (w) privileges to the moodledata directory and its sub-directories (-R), and make sure that Moodle keeps these privileges for all the files that are created or deposited in the directory, irrespective of the Moodle user who creates or downloads the files.


Download 345.09 Kb.

Share with your friends:
1   2   3   4   5   6   7   8   9   10   ...   13




The database is protected by copyright ©ininet.org 2024
send message

    Main page