Emalawi19's picture
Update start.sh
de3cdcb verified
Raw
History Blame Contribute Delete
535 Bytes
#!/bin/bash
# 1. Start the MySQL/MariaDB service
service mariadb start
sleep 3
# 2. Setup master database credentials
mysql -e "CREATE USER IF NOT EXISTS 'admin'@'localhost' IDENTIFIED BY 'orchestrator_master_pass';"
mysql -e "GRANT ALL PRIVILEGES ON *.* TO 'admin'@'localhost' WITH GRANT OPTION;"
mysql -e "FLUSH PRIVILEGES;"
# 3. Ensure Nginx can read the repository files
chown -R www-data:www-data /app
# 4. Start PHP FastCGI
service php8.1-fpm start
# 5. Start Nginx
echo "Starting Nginx web server..."
nginx -g "daemon off;"