tikiwiki/entrypoint.sh

41 lines
1.3 KiB
Bash
Raw Normal View History

2023-04-10 21:59:09 +02:00
#!/bin/bash
2023-04-11 21:48:35 +02:00
set -e
echo "Starting Tikiwiki"
install() {
echo "Install"
2023-04-13 21:44:55 +02:00
sudo -u tikiwiki php console.php database:configure --host $MYSQL_HOST $MYSQL_USER $MYSQL_PASSWORD $MYSQL_DATABASE
sudo -u tikiwiki php console.php database:install
sudo -u tikiwiki php console.php installer:lock
install_packages
2023-04-11 21:48:35 +02:00
update
}
2023-04-13 21:44:55 +02:00
install_packages() {
sudo -u tikiwiki php console.php package:install TikiManager
sudo -u tikiwiki php console.php package:install PDFjsViewer
sudo -u tikiwiki php console.php package:install MediaAlchemyst
sudo -u tikiwiki php console.php package:install diagram
sudo -u tikiwiki php console.php package:install mPDF
sudo -u tikiwiki php console.php package:install Lozad
sudo -u tikiwiki php console.php package:install FakerPHP
sudo -u tikiwiki php console.php package:install Expose
sudo -u tikiwiki php console.php package:install CasperJS
sudo -u tikiwiki php console.php package:install PhpReadability
sudo -u tikiwiki php console.php package:install WebODF
sudo -u tikiwiki php console.php package:install TesseractOCR
sudo -u tikiwiki php console.php package:install FullCalendarScheduler
}
2023-04-11 21:48:35 +02:00
update() {
echo "Update"
2023-04-13 21:44:55 +02:00
sudo -u tikiwiki php console.php database:update
sudo -u tikiwiki php console.php package:update
2023-04-11 21:48:35 +02:00
}
[ -s ./db/local.php ] && update || install
2023-04-10 21:59:09 +02:00
exec $@