DownloadContents
PHP
Composer
Docker
MySQl
Redis
Jwt
Nginx
Testing
Rate limiting
Installation
docker compose up -d --build
docker compose exec app bash
chmod -R 777 /var/www/html/storage/ /var/www/html/bootstrap/
cp .env.example .env
composer install
docker compose exec app php artisan jwt:secret
docker compose exec app php artisan migrate:fresh --seed
env config
-
mysql
DB_CONNECTION=mysql
DB_HOST=db
DB_PORT=3306
DB_DATABASE=laravel
DB_USERNAME=laravel
DB_PASSWORD=laravel
-
redis
CACHE_DRIVER=redis
REDIS_CLIENT=predis
REDIS_HOST=redis
REDIS_PASSWORD=null
REDIS_PORT=6379
### Usage
Insomnia_2024-12-13.json
Testing
cp .env .env.testing
docker-compose exec app php artisan config:clear
docker-compose exec app php artisan cache:clear
docker-compose exec app php artisan config:cache
docker-compose exec app php artisan migrate:fresh --seed --env=testing
docker-compose exec app php artisan test
|