-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
92 lines (85 loc) · 2.07 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
version: "3.6"
services:
percona:
image: percona:8
command:
- "mysqld"
- "--max-connections=1000"
- "--innodb_buffer_pool_size=2G"
- "--innodb_log_file_size=1G"
- "--innodb_flush_method=O_DIRECT"
ports:
- "3306:3306"
environment:
- MYSQL_ALLOW_EMPTY_PASSWORD=yes
- MYSQL_USER=internal
- MYSQL_PASSWORD=dev
- MYSQL_DATABASE=test
deploy:
mode: replicated
replicas: 1
redis:
image: redis:6.0.9-alpine
command:
- "redis-server"
- "--appendonly yes"
- "--requirepass dev"
- "--maxmemory 256mb"
- "--maxmemory-policy volatile-lru"
ports:
- "6379:6379"
deploy:
mode: replicated
replicas: 1
parity:
image: parity/parity:v2.7.2-stable
command:
- "--config=dev"
- "--port=30304"
- "--jsonrpc-port=8645"
- "--ws-port=8646"
- "--reseal-min-period=0"
- "--min-gas-price=0"
- "--unsafe-expose"
ports:
- "8645:8645"
- "8646:8646"
- "30304:30304"
deploy:
mode: replicated
replicas: 1
postgres:
image: postgres:13-alpine
ports:
- "5432:5432"
environment:
- POSTGRES_USER=internal
- POSTGRES_PASSWORD=dev
deploy:
mode: replicated
replicas: 1
cockroachdb:
image: cockroachdb/cockroach:v20.1.8
command:
- start
- --insecure
ports:
- "26257:26257"
deploy:
mode: replicated
replicas: 1
mongo:
image: mongo:4.4.1-bionic
ports:
- "27017:27017"
environment:
MONGO_INITDB_ROOT_USERNAME: internal
MONGO_INITDB_ROOT_PASSWORD: dev
MONGO_INITDB_DATABASE: test
deploy:
mode: replicated
replicas: 1
# Usage
# docker stack deploy --compose-file=infra/compose.yml storage;
# To create your own DB, for example dev
# CONTAINER_NAME=$(docker container ls --format '{{.Names}}' | grep percona) && docker exec -i $CONTAINER_NAME mysql -u root -e "DROP DATABASE IF EXISTS dev;CREATE DATABASE dev;GRANT ALL PRIVILEGES ON dev.* TO 'internal'@'%';";