-
-
Notifications
You must be signed in to change notification settings - Fork 83
/
docker-compose-apache.yaml
executable file
·92 lines (86 loc) · 2.03 KB
/
docker-compose-apache.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
version: "3.8"
services:
vvveb-install:
build:
context: .
dockerfile: Dockerfile-apache
restart: "no"
depends_on:
- vvveb-app
- db
links:
- db
# Sleep is required so that the command is run after mysql is initialized.
#command: >
# /bin/sh -c'
# sleep 10;
# php cli.php install module=index host=db user=vvveb password=vvveb database=vvveb admin[email][email protected] admin[password]=admin
# '
working_dir: /var/www/html
# https://docs.vvveb.com/installation#cli add engine=sqlite to cli parameters to install with sqlite
entrypoint:
[
"bash",
"-c",
"sleep 10 && php cli.php install module=index host=db user=vvveb password=vvveb database=vvveb admin[email][email protected] admin[password]=admin",
]
# add shared volume
volumes:
- vvveb_data:/var/www/html
- db_data:/var/lib/mysql
networks:
- php-network
vvveb-app:
build:
context: .
dockerfile: Dockerfile-apache
container_name: vvveb-cms
ports:
- "80:80"
depends_on:
- db
links:
- db
# add shared volume
volumes:
- vvveb_data:/var/www/html
- db_data:/var/lib/mysql
networks:
- php-network
db:
image: mysql:latest
#command: --default-authentication-plugin=mysql_native_password
restart: always
environment:
MYSQL_ROOT_PASSWORD: vvveb
MYSQL_DATABASE: vvveb
MYSQL_USER: vvveb
MYSQL_PASSWORD: vvveb
networks:
- php-network
volumes:
- vvveb_data:/var/www/html
- db_data:/var/lib/mysql
phpmyadmin:
image: phpmyadmin/phpmyadmin:latest
container_name: phpmyadmin-cms
ports:
- "8081:80"
environment:
- PMA_ARBITRARY=1
- PMA_USER=vvveb
- PMA_PASSWORD=vvveb
- PMA_HOST=db
- PMA_PORT=3306
depends_on:
- db
networks:
- php-network
# volumes:
# - db_data:/var/lib/mysql
volumes:
db_data:
vvveb_data:
networks:
php-network:
driver: bridge