Files
finance/docker-compose.yml
T
Ümit Tunç 5c96b6b72e Update Docker configuration and Dockerfile for Laravel application
- Changed the Docker image for the app service to 'truncgil-finance-app' and updated the container name accordingly.
- Modified the web service to use 'truncgil-finance-web' and changed the port mapping to 8081.
- Upgraded the database image to MySQL 8.0 and updated the container name to 'truncgil-finance-db', adding a restart policy.
- Added environment variables for timezone and application settings in the app service.
- Updated the Dockerfile to use PHP 8.2, added necessary dependencies, and configured cron jobs for Laravel tasks.
- Enhanced file permission settings for the application directory to improve security and functionality.

These changes improve the overall configuration and performance of the Laravel application within the Docker environment.
2025-01-20 22:10:47 +03:00

48 lines
966 B
YAML

services:
app:
build:
context: .
dockerfile: Dockerfile
image: truncgil-finance-app
container_name: truncgil-finance-app
volumes:
- .:/var/www
networks:
- laravel-network
environment:
- TZ=Europe/Istanbul
- APP_ENV=production
- APP_DEBUG=false
web:
image: nginx:alpine
container_name: truncgil-finance-web
ports:
- "8081:80"
volumes:
- .:/var/www
- ./nginx/default.conf:/etc/nginx/conf.d/default.conf
networks:
- laravel-network
db:
image: mysql:8.0
container_name: truncgil-finance-db
restart: unless-stopped
environment:
MYSQL_ROOT_PASSWORD: root
MYSQL_DATABASE: truncgil_finance
MYSQL_USER: truncgil_finance
MYSQL_PASSWORD: "QWEFaca123++"
volumes:
- db_data:/var/lib/mysql
networks:
- laravel-network
ports:
- "3307:3306"
networks:
laravel-network:
volumes:
db_data: