-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.local.yml
More file actions
85 lines (84 loc) · 2.06 KB
/
docker-compose.local.yml
File metadata and controls
85 lines (84 loc) · 2.06 KB
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
version: '3'
services:
mongodb:
image: mongo:latest
hostname: mangodb
restart: always
ports:
- "27017:27017"
volumes:
- ./mongodb-data:/data/db
environment:
MONGO_INITDB_ROOT_USERNAME: mangodb
MONGO_INITDB_ROOT_PASSWORD: mangodb
db:
image: mysql:latest
restart: always
environment:
MYSQL_ROOT_PASSWORD: koakoatutorial
MYSQL_DATABASE: koa
MYSQL_USER: koa-tutorial
MYSQL_PASSWORD: koa-tutorial
volumes:
- ./data:/var/lib/mysql
ports:
- "3306:3306"
js-dev:
build:
context: .
dockerfile: ./dockerfiles/node.16.19.1.Dockerfile
command: "echo 'Hello';"
depends_on:
- db
- mongodb
- localstack
ports:
- ${KOA_PORT_EXTERNAL}:${KOA_PORT}
volumes:
- type: bind
source: ${JS_WORKSPACE}/${JS_PROJECT_NAME}
target: /code
- type: bind
source: ${SSH_PUBLIC_KEYS_DIR}
target: /root/.ssh
- type: bind
source: ${SSH_PUBLIC_KEYS_DIR}
target: /home/node/.ssh
- ${NODEJS_BUILD_FOLDER}:${NODEJS_BUILD_INTERNAL_FOLDER}
koa-app:
build:
context: .
dockerfile: ./dockerfiles/node.16.19.1.slim.Dockerfile
command: "node app.js api -p"
depends_on:
- db
- mongodb
- localstack
ports:
- ${KOA_PORT_EXTERNAL}:${KOA_PORT}
volumes:
- type: bind
source: ${JS_WORKSPACE}/${JS_PROJECT_NAME}
target: /code
- type: bind
source: ${SSH_PUBLIC_KEYS_DIR}
target: /root/.ssh
- type: bind
source: ${SSH_PUBLIC_KEYS_DIR}
target: /home/node/.ssh
- ${NODEJS_BUILD_FOLDER}:${NODEJS_BUILD_INTERNAL_FOLDER}
localstack:
image: localstack/localstack:latest
hostname: localstack
environment:
SERVICES: s3
DEBUG: 1
DEFAULT_REGION: us-east-1
DATA_DIR: /tmp/localstack/data
AWS_ACCESS_KEY_ID: test
AWS_SECRET_ACCESS_KEY: test
AWS_DEFAULT_REGION: us-east-1
ports:
- 4566:4566
volumes:
- ./localstack_tmp:/tmp/localstack