Blame view

docker/docker-compose.yml 1.29 KB
2964317a   zhangqijia   feat: docker安装部署
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
  version: '3.3'
  services:
    db:
      image: mongo
      container_name: mongodb-pro2d
      ports:
        - '27017:27017'
      restart: always
      environment:
        MONGO_INITDB_ROOT_USERNAME: root #mongo默认的账号
        MONGO_INITDB_ROOT_PASSWORD: root #mongo默认的密码
      volumes:
        - ./.docker/mongo_data:/data/db
        - ./.docker/mongo.conf:/data/mongo.conf
  #    command: --config /data/mongo.conf # 配置文件
      command: [--auth] # 配置文件
02894885   zhangqijia   fix: del etcd. ad...
17
18
19
20
21
22
  #  etcd:
  #    image: xieyanze/etcd3
  #    container_name: etcd3-pro2d
  #    restart: always
  #    ports:
  #    - '2379:2379'
2964317a   zhangqijia   feat: docker安装部署
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
    redis:
      image: redis:latest
      container_name: redis-pro2d
      restart: always
      ports:
      - '6100:6379'
      volumes:
        - ./.docker/redis_data:/data/db
  
    account:
      image: pro2d
      container_name: account-pro2d
      restart: always
      ports:
        - '8080:8080'
329a4f25   zhangqijia   fix: docker安装部署 u...
38
        - '6061:6060' #debug
2964317a   zhangqijia   feat: docker安装部署
39
40
      volumes:
        - ./.docker/account_logs:/data/logs
02894885   zhangqijia   fix: del etcd. ad...
41
        - ./conf.yml:/data/conf/conf.yml
2964317a   zhangqijia   feat: docker安装部署
42
43
44
45
46
47
48
49
      working_dir: /data
      command: [./http]
    game:
      image: pro2d
      container_name: game-pro2d
      restart: always
      ports:
        - '8849:8849'
329a4f25   zhangqijia   fix: docker安装部署 u...
50
51
        - '6060:6060' #debug
        - '8880:8880' #gm
2964317a   zhangqijia   feat: docker安装部署
52
53
      volumes:
        - ./.docker/game_logs:/data/logs
02894885   zhangqijia   fix: del etcd. ad...
54
        - ./conf.yml:/data/conf/conf.yml
2964317a   zhangqijia   feat: docker安装部署
55
56
      working_dir: /data
      command: [./game]