- Clone or download
git clone https://github.com/YubiRepo/test-api
- CD into
/test-api
cd test-api
- Install Laravel dependency
composer install
- Create copy of
.env
cp .env.example .env
- Generate laravel key
php artisan key:generate
- Set database name and account in
.env
DB_DATABASE=test_api
DB_USERNAME=root
DB_PASSWORD=
- Run Laravel migrate and seeder
php artisan migrate --seed
- Create the symbolic link
php artisan storage:link
- Start development server
php artisan serve
- Login
{
"email": "admin@example.com",
"password": "password"
}
Go to /api/login
Apply changes to .env
file:
APP_ENV=production
APP_DEBUG=false
Run these commands sequentially
composer install --optimize-autoloader --no-dev
php artisan storage:link
php artisan optimize