forked from HemaSahuRathore/CI-CD-using-Docker
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
40 lines (40 loc) · 861 Bytes
/
docker-compose.yml
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
version: '3.3'
services:
db:
image: mysql:5.7
volumes:
- db_vol:/var/lib/mysql
- ./mysql-dump:/docker-entrypoint-initdb.d
environment:
MYSQL_ROOT_PASSWORD: root
MYSQL_DATABASE: testdb1
MYSQL_USER: testuser
MYSQL_PASSWORD: root
ports:
- 3306:3306
phpmyadmin:
depends_on:
- db
image: phpmyadmin/phpmyadmin
ports:
- '8081:80'
environment:
PMA_HOST: db
MYSQL_ROOT_PASSWORD: root
web:
build:
context: .
depends_on:
- db
image: tomcat
volumes:
- ./target/LoginWebApp-1.war:/usr/local/tomcat/webapps/LoginWebApp-1.war
ports:
- '8082:8080'
environment:
MYSQL_ROOT_PASSWORD: root
MYSQL_DATABASE: testdb1
MYSQL_USER: testuser
MYSQL_PASSWORD: root
volumes:
db_vol: