IDE:Mediawiki Installieren: Unterschied zwischen den Versionen
Zur Navigation springen
Zur Suche springen
// via Wikitext Extension for VSCode |
|||
| (Eine dazwischenliegende Version desselben Benutzers wird nicht angezeigt) | |||
| Zeile 26: | Zeile 26: | ||
server_name localhost; | server_name localhost; | ||
root /var/www/mediawiki; | root /var/www/mediawiki; | ||
index index.php index.html index.htm; | index index.php index.html index.htm; | ||
| Zeile 53: | Zeile 49: | ||
sudo systemctl reload nginx | sudo systemctl reload nginx | ||
</code> | </code> | ||
==Backup erstellen== | |||
<pre> | |||
cd /home/thorsten | |||
gh repo clone thorstenkloehn/Download | |||
sudo chmod 777 -R Download | |||
cd /home/thorsten/Download | |||
sudo rm /home/thorsten/Download/pagedump.xml | |||
ssh root@ahrensburg.city "php /var/www/mediawiki/mediawiki/maintenance/dumpBackup.php --full" > /home/thorsten/Download/pagedump.xml | |||
git add pagedump.xml | |||
git commit -m "Backup" | |||
git push | |||
</pre> | |||
Aktuelle Version vom 22. Oktober 2025, 00:36 Uhr
Postgres Datenbank erstellen
sudo -u postgres -i
createdb -E UTF8 -O thorsten mediawiki
exit
Mediawiki installieren
cd /var/www
sudo git clone https://gerrit.wikimedia.org/r/mediawiki/core.git mediawiki
sudo cd mediawiki
sudo git tag -l | sort -V
sudo git checkout 1.41.0
sudo git submodule update --init --recursive
sudo chown -R www-data:www-data /var/www/mediawiki
sudo chmod -R 755 /var/www/mediawiki
Hochladen der Konfiguration
sudo scp /home/thorsten/Downloads/LocalSettings.php thorsten@ahrensburg.city:/var/www/mediawiki/LocalSettings.php
Nginx Konfiguration für lokale MediaWiki-Installation
sudo nano /etc/nginx/conf.d/start.conf
Füge die folgende Konfiguration ein:
server {
listen 80;
server_name localhost;
root /var/www/mediawiki;
index index.php index.html index.htm;
location / {
try_files $uri $uri/ /index.php?$args;
}
location ~ \.php$ {
include snippets/fastcgi-php.conf;
fastcgi_pass unix:/var/run/php/php8.3-fpm.sock;
}
location ~ /\.ht {
deny all;
}
}
Aktiviere die Konfiguration und starte Nginx neu:
sudo systemctl reload nginx
Backup erstellen
cd /home/thorsten gh repo clone thorstenkloehn/Download sudo chmod 777 -R Download cd /home/thorsten/Download sudo rm /home/thorsten/Download/pagedump.xml ssh root@ahrensburg.city "php /var/www/mediawiki/mediawiki/maintenance/dumpBackup.php --full" > /home/thorsten/Download/pagedump.xml git add pagedump.xml git commit -m "Backup" git push