docker-compose tidy and clean

This commit is contained in:
Hüseyin Mert 2020-04-15 06:52:37 +03:00
parent 894fde1603
commit b63ad43742
1 changed files with 18 additions and 25 deletions

View File

@ -2,35 +2,22 @@ version: '3.7'
services: services:
nginx: nginx:
image: nginx build: ./nginx
ports: ports:
- 8080:80 - 8080:80
volumes: volumes:
- ./nginx/conf.d:/etc/nginx/conf.d:ro - ./nginx/conf.d:/etc/nginx/conf.d:ro
- .:/var/www/akaunting.test - app-data:/var/www/akaunting
restart: unless-stopped restart: unless-stopped
networks:
akaunting:
aliases:
- akaunting.test
app: php:
build: ./php build: ./php
user: "1000:1000"
expose:
- 9000
volumes: volumes:
- .:/var/www/akaunting.test - app-data:/var/www/akaunting
restart: unless-stopped restart: unless-stopped
environment:
APP_DEBUG: "true"
networks:
- akaunting
mysql: db:
image: mysql:5 image: mysql:latest
ports:
- 3306:3306
volumes: volumes:
- db-data:/var/lib/mysql - db-data:/var/lib/mysql
environment: environment:
@ -38,12 +25,18 @@ services:
MYSQL_DATABASE: akaunting_db MYSQL_DATABASE: akaunting_db
MYSQL_USER: akaunting_admin MYSQL_USER: akaunting_admin
MYSQL_PASSWORD: akaunting_password MYSQL_PASSWORD: akaunting_password
networks:
- akaunting
command: --default-authentication-plugin=mysql_native_password command: --default-authentication-plugin=mysql_native_password
volumes:
db-data:
networks: # image: postgres:alpine
akaunting: # volumes:
# - db-data:/var/lib/postgresql/data
# environment:
# POSTGRES_DB: akaunting_db
# POSTGRES_USER: akaunting_admin
# POSTGRES_PASSWORD: akaunting_password
# ports:
# - "5432:5432"
volumes:
app-data:
db-data: