åæ¸ã
Ubuntu 24.04ãMoodleãµã¼ãã«ãã¦ãADã¨ã®é£æºã¾ã§è¡ãã
ããããã¤ã³ã¹ãã¼ã«
ApacheãMySQLãPHPãã¤ã³ã¹ãã¼ã«
Ubuntuã«ãã°ã¤ã³ãã以ä¸ã³ãã³ããå®è¡ããã
sudo apt install apache2 mysql-client mysql-server php libapache2-mod-php
PHPã®ã¢ã¸ã¥ã¼ã«ãã¤ã³ã¹ãã¼ã«
以ä¸ã³ãã³ããå®è¡ãPHPã®ã¢ã¸ã¥ã¼ã«ãã¤ã³ã¹ãã¼ã«ããã
sudo apt install graphviz aspell ghostscript clamav php8.3-pspell php8.3-curl php8.3-gd php8.3-intl php8.3-mysql php8.3-xml php8.3-xmlrpc php8.3-ldap php8.3-zip php8.3-soap php8.3-mbstring
çµãã£ããApache2ãåèµ·åããã
sudo service apache2 restart
Moodleããã¦ã³ãã¼ã
ã¾ãã¯ä¸è¨ã³ãã³ãã§Gitãã¤ã³ã¹ãã¼ã«ããã
sudo apt install git
Gitãã¤ã³ã¹ãã¼ã«ã§ãããä¸è¨ã³ãã³ããé ã«å®è¡ãã¦ãããApache2ç¨ã®ãã©ã«ãã«Moodleãæ ¼ç´ããã¨ããã¾ã§è¡ãã
cd /opt
sudo git clone git://git.moodle.org/moodle.git
cd moodle
sudo git branch -a
sudo git branch âtrack MOODLE_405_STABLE origin/MOODLE_405_STABLE
sudo git checkout MOODLE_405_STABLE
sudo cp -R /opt/moodle /var/www/html
sudo mkdir /var/moodledata
sudo chmod -R 777 /var/moodledata
sudo chmod -R 0755 /var/www/html/moodle
MySQLãã»ããã¢ãã
MySQLã®è¨å®ãã¡ã¤ã«(/etc/mysql/mysql.conf.d/mysqld.cnf)ã®[mysqld]ã»ã¯ã·ã§ã³æä¸é¨ã«ã以ä¸ã追è¨ããã
default_storage_engine = innodb
innodb_file_per_table = 1
以ä¸ã³ãã³ãã§MySQLãåèµ·åããã
sudo service mysql restart
MySQLãèµ·åããMoodleç¨ã®DBã¨ãã¦ã¼ã¶ã¨ãä½ãã
sudo mysql -u root -p
**Ubuntuã«ãã°ã¤ã³ããã¦ã¼ã¶ã®ãã¹ã¯ã¼ããå
¥å**
MySQLãèµ·åããã以ä¸SQLãå®è¡
CREATE DATABASE moodle DEFAULT CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;
CREATE USER âmoodledudeâ@âlocalhostâ IDENTIFIED BY âpasswordformoodledudeâ;
GRANT ALL ON moodle.* TO âmoodledudeâ@âlocalhostâ WITH GRANT OPTION;
quit;ã§çµäºã
Moodleãã»ããã¢ãã
Moodleèªèº«ã§è¨å®ãã¡ã¤ã«ãä½ããããã以ä¸ã³ãã³ããæã£ã¦ããã
sudo chmod -R 777 /var/www/html/moodle
é©å½ãªãã·ã³ã®ãã©ã¦ã¶ãã以ä¸ã®URLã«ã¢ã¯ã»ã¹ã
http://192.168.176.4/moodle
Moodleã«ã¢ã¯ã»ã¹ã§ãããã»ããã¢ããç»é¢ã表示ãããã®ã§ãç»é¢ã«å¾ã£ã¦è¨å®ãé²ãããMySQLã®è¨å®ã§ã¯ãå
ã»ã©è¨å®ããå
容ã«åããããã®ãå
¥åããã æ¬æé ã®å
容ããã®ã¾ã¾å®æ½ãã¦ãããä¸å³ã®æãã«ãªãã
ãmax_input_varsã¯5000以ä¸ã§ãï¼ãã¿ãããªã¡ãã»ã¼ã¸ãã§ãããphp.iniãç·¨éãã¦max_input_varsã5000以ä¸ã«ããã
èªåã®å ´åã¯ã/etc/php/8.3/apache2/php.iniãã«ãã£ãã(apache2ã使ãPHPã®è¨å®ãã¡ã¤ã«ã¯ããã£ã½ãï¼)
管çè
ã¦ã¼ã¶ã®ååã¨ãã¿ã¤ã ã¾ã¼ã³ã¨ããµã¤ãåã¨ãã好ã¿ã§å
¥åãã¦å®äºã
ActiveDirectoryã¨é£æº
ADãµã¼ãã®æä½
Windows Firewallã§TCPæ¥ç¶ã許å¯ããã ã³ã³ããçããWindows Firewallã®è¨å®ç»é¢ã¸é·ç§»ãããåä¿¡ã®è¦åãã«æ°ããè¦åã追å ããã(ãããã³ã«ã¯TCPããã¼ãçªå·ã¯389)
Moodleã®ç®¡çè
ç¨ã¦ã¼ã¶ãä½æãããããActive Directoryã¦ã¼ã¶ã¼ã¨ã³ã³ãã¥ã¼ã¿ã¼ãã§ãUsersããå³ã¯ãªãã¯ããæ°è¦ä½æãâãã¦ã¼ã¶ã¼ããé¸æããã
以ä¸ã®éãã¦ã¼ã¶ã¼ãä½æããããã¹ã¯ã¼ãã¯P@ssword01ã«ããã
LDAPã«ã¢ã¯ã»ã¹ããã¢ã«ã¦ã³ããä½æãããããå
ã»ã©ã¨åãè¦é ã§ä»¥ä¸ã¦ã¼ã¶ãä½æããããã¹ã¯ã¼ãã¯P@ssword01ã«ããã
Moodleç¨ã®SG(管çè
ç¨ã¨è¬åº§ä½æè
ç¨)ãä½æãããããActive Directoryã¦ã¼ã¶ã¼ã¨ã³ã³ãã¥ã¼ã¿ã¼ãã§ãUsersããå³ã¯ãªãã¯ããæ°è¦ä½æãâãã°ã«ã¼ãããé¸æããã以ä¸2ã¤ã®ã°ã«ã¼ããä½ãã
Moodleã®è¨å®
é©å½ãªãã·ã³ã®ãã©ã¦ã¶ã§ä»¥ä¸ã«ã¢ã¯ã»ã¹ã管çè
ã¢ã«ã¦ã³ãã§ãã°ã¤ã³ããã
http://192.168.176.4/moodle
ããµã¤ã管çãã¿ãã§ããã©ã°ã¤ã³ãâãèªè¨¼ãâãèªè¨¼ã®ç®¡çããé¸æã
ãLDAPãµã¼ããè¡ã®ãè¨å®ããé¸æããLDAPãµã¼ãè¨å®ã-ããã¹ãURLãã«ãã¡ã³ã³ã®IPã¢ãã¬ã¹ãå
¥åã
ããã¤ã³ãè¨å®ãã«ãã£ãä½ã£ãLDAPã¢ã¯ã»ã¹ç¨ã®ã¦ã¼ã¶ã®DNã¨ãã¹ã¯ã¼ããå
¥åã
ã¦ã¼ã¶ã«ãã¯ã¢ããè¨å®ã«ããããå
¥åããã
ã·ã¹ãã ãã¼ã«ãããã³ã°ã«Moodleç¨ã«ä½ã£ãSGãè¨å®ããã
ãã¼ã¿ãããã³ã°ã¯ã¡ã¢ãã¾ã§è¨å®ããããããä¸ã¯ããã©ã«ãã®ã¾ã¾ã
ãã¡ã¤ã³ã¦ã¼ã¶ã§ã®ãã°ã¤ã³ã¯ãã¦ã¼ã¶ãã°ãªã³åã§ã§ããã ä»»æã®ã¦ã¼ã¶ã§ãã°ã¤ã³ã§ãããã¨ã確èªãä»åã¯çµã(SGã¯ä½¿ã£ã¦ãªããã©ããã)