-
Notifications
You must be signed in to change notification settings - Fork 12
/
Copy pathdocker-compose.yml
60 lines (52 loc) · 1.79 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
#######################################################
# Nano with docker-compose
#
# Please edit only if you know what you are doing.
# Please use spaces when editing.
# If you need any help, join our discord server at http://discord.nanobot.pw
version: '3'
services:
nano:
# ##########
# IMPORTANT: This should only be used for building an image from source or for testing!
# tl;dr: Don't uncomment this if you don't know what you are doing.
# ##########
# build:
# context: .
# dockerfile: Dockerfile
image: defaltsimon/nano:latest
######
# Both nano and redis databases share the same directory - /data
# This mounts the data directory (in your current directory) to data/ inside the container
# so your configuration is modified outside of the container
######
volumes:
- ./data:/data
# This makes sure redis-data and redis-cache are started first.
depends_on:
- redis-data
- redis-cache
#########################
# REDIS-DATA instance
# Contains all data, related to the user
#########################
redis-data:
container_name: "redis-data"
image: redis
# Mounts all database files into your data/ directory
volumes:
- ./data:/data
- ./data/redis.conf:/usr/local/etc/redis/redis.conf
command: "redis-server /usr/local/etc/redis/redis.conf"
#########################
# REDIS-CACHE instance
# As the name suggests, this db contains cached data such as tf2 items, jokes, etc...
#########################
redis-cache:
container_name: "redis-cache"
image: redis
# Mounts all database files into your data/ directory
volumes:
- ./data:/data
- ./data/redisCache.conf:/usr/local/etc/redis/redis.conf
command: "redis-server /usr/local/etc/redis/redis.conf"