02 - Installation rapide (5 min)
manipulation en ssh
# 1. Télécharger
cd /var/www/html && tar -xzf educapro-v1.4.tar.gz && cd monsite
# 2. Dépendances
composer install --no-dev --optimize-autoloader
# 3. Configuration
cp .env.example .env && php artisan key:generate
nano .env # DB_DATABASE=educapro, DB_USERNAME=root, DB_PASSWORD=xxx
# 4. Base de données
mysql -u root -p -e "CREATE DATABASE educapro CHARACTER SET utf8mb4;"
php artisan migrate --seed
# 5. Permissions
sudo chown -R www-data:www-data storage bootstrap/cache
sudo chmod -R 775 storage bootstrap/cache
mkdir -p public/images/exercices && sudo chown -R www-data:www-data public/imagesphp artisan tinker
>>> $u = new App\Models\User();
>>> $u->fill(['name'=>'Admin','first_name'=>'Admin','last_name'=>'EducaPro','email'=>'[email protected]','password'=>bcrypt('Admin2025'),'role'=>'admin','is_active'=>true])->save();
>>> exitLast updated