-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
executable file
·112 lines (105 loc) · 2.43 KB
/
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
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
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
# docker-compose.yml
## -------------------------------------------------------------------------
## DB ADMIN: 4170
## VSCODE: 8080
## NODEJS PORT: 3000
## REDIS PORT: 6379 // Not accessible from outside.
## SQL SERVER PORT: 1433
## -------------------------------------------------------------------------
version: '3.4'
services:
# -- REDIS Cache ---
redis_cache:
image: redis
container_name: redis_cache
restart: always
ports:
- '6379:6379/tcp'
networks:
vscode:
aliases:
- vscode
# -- SQL SERVER ---
mssql:
image: microsoft/mssql-server-linux:latest
container_name: mssql
ports:
- 1433:1433
volumes:
- /var/opt/mssql
# we copy our scripts onto the container
- ./sql:/usr/src/app
# bash will be executed from that path, our scripts folder
working_dir: /usr/src/app
# run the entrypoint.sh that will import the data AND sqlserver
command: sh -c ' chmod +x ./start.sh; ./start.sh & /opt/mssql/bin/sqlservr;'
environment:
ACCEPT_EULA: 'Y'
SA_PASSWORD: SuperP4ssw0rd!
networks:
vscode:
aliases:
- vscode
# -- SQL SERVER CLIENT---
sqlpad:
image: 'sqlpad/sqlpad:latest'
hostname: 'sqlpad'
container_name: sqlpad
ports:
- '4170:3000'
environment:
- SQLPAD_DEBUG=true
- SQLPAD_ADMIN=admin@admin.com
- SQLPAD_ADMIN_PASSWORD=12345
#- DISABLE_USERPASS_AUTH=true
#- SQLPAD_QUERY_RESULT_MAX_ROWS=50000
#- SQLPAD_ALLOW_CONNECTION_ACCESS_TO_EVERYONE=true
volumes:
- ./sqlpad:/var/lib/sqlpad
networks:
vscode:
aliases:
- vscode
# -- NODE JS---
nodejs:
container_name: nodejs
build:
context: ./nodejs
dockerfile: Dockerfile
links:
- redis_cache
- mssql
networks:
vscode:
aliases:
- vscode
command: >
/bin/bash -c "
sleep 10s
npm run dev
"
ports:
- '3000:3000/tcp'
environment:
- NODE_ENV=development
- ENV_NAME=dev
- PORT=3000
volumes:
- ./nodejs/src:/app/src
# -- VSCODE IDE---
vscode:
container_name: vscode
image: didar911/vscode
networks:
vscode:
aliases:
- vscode
ports:
- '8080:8080/tcp'
environment:
- PASSWORD=skybird
volumes:
- ./nodejs/src/:/home/coder/project
networks:
vscode:
driver: bridge