IT/Software/Mediawiki/How to Install MediaWiki: Difference between revisions
Jump to navigation
Jump to search
Access restrictions were established for this page. If you see this message, you have no access to this page.
Player5501 (talk | contribs) m (added punctuation) |
m (Nathan moved page IT/Mediawiki/How to Install MediaWiki to IT/Software/Mediawiki/How to Install MediaWiki) |
||
(13 intermediate revisions by 2 users not shown) | |||
Line 2: | Line 2: | ||
---- | ---- | ||
* Ubuntu Server 18.04.3 LTS | * Ubuntu Server 18.04.3 LTS | ||
* In my install | * In my install I have all additions enabled. | ||
* Apache2 Installed. | |||
* Installing and setting up MariaDB for MediaWiki is also covered on this page. | |||
=== Install | === Install MariaDB === | ||
---- | ---- | ||
# | #<code>sudo apt-get install mariadb-server mariadb-client</code> | ||
#<code>sudo mysql_secure_installation</code> | |||
# | # Restart MariaDB | ||
#* <code>sudo systemctl restart mariadb.service</code> | |||
=== Create MediaWiki Database === | |||
---- | ---- | ||
==== | #<code>sudo mysql -u root -p</code> | ||
#Then create a database called mediawiki | |||
#*<code>CREATE DATABASE mediawiki;</code> | |||
#Create a database user called mediawikiuser with new password | |||
#*<code>CREATE USER 'mediawikiuser'@'localhost' IDENTIFIED BY 'new_password_here';</code> | |||
#Then grant the user full access to the database. | |||
#*<code>GRANT ALL ON mediawiki.* TO 'mediawikiuser'@'localhost' IDENTIFIED BY 'user_password_here' WITH GRANT OPTION;</code> | |||
# Save and Exit | |||
#*<code>FLUSH PRIVILEGES;</code> | |||
#*<code>EXIT;</code> | |||
===Install PHP Modules=== | |||
---- | |||
* <code>sudo apt install php7.2 php7.2-mbstring php7.2-xml php7.2-mysql php7.2-gd php7.2-intl</code> | |||
=== Download and Extract MediaWiki === | |||
---- | |||
# Navigate to webroot. | |||
#* <code>cd /var/www/html</code> | |||
# Remove default index.html | |||
#* <code>rm index.html</code> | |||
# Download and extract [https://www.mediawiki.org/wiki/Download Mediawiki] tarball latest stable version 1.34.0 at time of writing. | |||
#* <code>wget https://releases.wikimedia.org/mediawiki/1.34/mediawiki-1.34.0.tar.gz</code> | |||
#Extract MediaWiki tarball | |||
#* <code>tar -xvf mediawiki-1.34.0.tar.gz</code> | |||
#Rename extracted folder to <strong>mediawiki</strong> | |||
#* <code>mv mediawiki-1.34.0 mediawiki</code> | |||
# Remove tarball | |||
#* <code>rm mediawiki-1.34.0.tar.gz</code> | |||
=== Web installation === | |||
---- | ---- | ||
*After you get to the "Connect to database" page input the following information | |||
#Database Host:<code>localhost</code> | |||
#Database Name:<code>mediawiki</code> | |||
#Database table prefix can be left blank. | |||
#Database Username:<code>mediawikiuser</code> | |||
#Database Password:<code>user_password_here</code> | |||
#Finsh the web instalation and then your wiki is all ready to be used. YAY! |
Latest revision as of 11:32, 17 January 2020
Prerequisites
- Ubuntu Server 18.04.3 LTS
- In my install I have all additions enabled.
- Apache2 Installed.
- Installing and setting up MariaDB for MediaWiki is also covered on this page.
Install MariaDB
sudo apt-get install mariadb-server mariadb-client
sudo mysql_secure_installation
- Restart MariaDB
sudo systemctl restart mariadb.service
Create MediaWiki Database
sudo mysql -u root -p
- Then create a database called mediawiki
CREATE DATABASE mediawiki;
- Create a database user called mediawikiuser with new password
CREATE USER 'mediawikiuser'@'localhost' IDENTIFIED BY 'new_password_here';
- Then grant the user full access to the database.
GRANT ALL ON mediawiki.* TO 'mediawikiuser'@'localhost' IDENTIFIED BY 'user_password_here' WITH GRANT OPTION;
- Save and Exit
FLUSH PRIVILEGES;
EXIT;
Install PHP Modules
sudo apt install php7.2 php7.2-mbstring php7.2-xml php7.2-mysql php7.2-gd php7.2-intl
Download and Extract MediaWiki
- Navigate to webroot.
cd /var/www/html
- Remove default index.html
rm index.html
- Download and extract Mediawiki tarball latest stable version 1.34.0 at time of writing.
- Extract MediaWiki tarball
tar -xvf mediawiki-1.34.0.tar.gz
- Rename extracted folder to mediawiki
mv mediawiki-1.34.0 mediawiki
- Remove tarball
rm mediawiki-1.34.0.tar.gz
Web installation
- After you get to the "Connect to database" page input the following information
- Database Host:
localhost
- Database Name:
mediawiki
- Database table prefix can be left blank.
- Database Username:
mediawikiuser
- Database Password:
user_password_here
- Finsh the web instalation and then your wiki is all ready to be used. YAY!