forked from veracode-demo-labs/verademo-javascript
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcompose.yaml
42 lines (39 loc) · 1.25 KB
/
compose.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
# Comments are provided throughout this file to help you get started.
# If you need more help, visit the Docker compose reference guide at
# https://docs.docker.com/compose/compose-file/
# Here the instructions define your application as two services called "todo-app" and “todo-database”
# The service “todo-app” is built from the Dockerfile in the /app directory,
# and the service “todo-database” uses the official MongoDB image
# from Docker Hub - https://hub.docker.com/_/mongo.
# You can add other services your application may depend on here.
services:
app:
container_name: verademo
build:
context: ./
depends_on:
- database
environment:
NODE_ENV: development
ports:
- 8000:8000
develop:
watch:
- path: package.json
action: rebuild
- path: ./
target: /app
action: sync
database:
image: mysql:8.0.37
container_name: mysql
command: '--authentication_policy=mysql_native_password'
#command:
#- /usr/local/bin/docker-entrypoint.sh mysqld > /dev/null 2>&1 & disown
environment:
- MYSQL_DATABASE=blab
- MYSQL_ALLOW_EMPTY_PASSWORD=1
volumes:
- ./db:/docker-entrypoint-initdb.d
ports:
- "3306:3306"