๐Ÿ“ฆ makeplane / plane

๐Ÿ“„ docker-compose-local.yml ยท 230 lines
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
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230services:
  plane-redis:
    image: valkey/valkey:7.2.11-alpine
    restart: unless-stopped
    networks:
      - dev_env
    volumes:
      - redisdata:/data
    ports:
      - "6379:6379"

  plane-mq:
    image: rabbitmq:3.13.6-management-alpine
    restart: unless-stopped
    networks:
      - dev_env
    volumes:
      - rabbitmq_data:/var/lib/rabbitmq
    env_file:
      - .env
    environment:
      RABBITMQ_DEFAULT_USER: ${RABBITMQ_USER}
      RABBITMQ_DEFAULT_PASS: ${RABBITMQ_PASSWORD}
      RABBITMQ_DEFAULT_VHOST: ${RABBITMQ_VHOST}

  plane-minio:
    image: minio/minio
    restart: unless-stopped
    networks:
      - dev_env
    entrypoint: >
      /bin/sh -c "
      mkdir -p /export/${AWS_S3_BUCKET_NAME} &&
      minio server /export --console-address ':9090' &
      sleep 5 &&
      mc alias set myminio http://localhost:9000 ${AWS_ACCESS_KEY_ID} ${AWS_SECRET_ACCESS_KEY} &&
      mc mb myminio/${AWS_S3_BUCKET_NAME} -p || true
      && tail -f /dev/null
      "
    volumes:
      - uploads:/export
    env_file:
      - .env
    environment:
      MINIO_ROOT_USER: ${AWS_ACCESS_KEY_ID}
      MINIO_ROOT_PASSWORD: ${AWS_SECRET_ACCESS_KEY}
    ports:
      - "9000:9000"
      - "9090:9090"

  plane-db:
    image: postgres:15.7-alpine
    restart: unless-stopped
    networks:
      - dev_env
    command: postgres -c 'max_connections=1000'
    volumes:
      - pgdata:/var/lib/postgresql/data
    env_file:
      - .env
    environment:
      PGDATA: /var/lib/postgresql/data
    ports:
      - "5432:5432"

  # web:
  #   build:
  #     context: .
  #     dockerfile: ./web/Dockerfile.dev
  #   restart: unless-stopped
  #   networks:
  #     - dev_env
  #   volumes:
  #     - ./web:/app/web
  #   env_file:
  #     - ./web/.env
  #   depends_on:
  #     - api
  #     - worker

  # space:
  #   build:
  #     context: .
  #     dockerfile: ./space/Dockerfile.dev
  #   restart: unless-stopped
  #   networks:
  #     - dev_env
  #   volumes:
  #     - ./space:/app/space
  #   depends_on:
  #     - api
  #     - worker
  #     - web

  # admin:
  #   build:
  #     context: .
  #     dockerfile: ./admin/Dockerfile.dev
  #   restart: unless-stopped
  #   networks:
  #     - dev_env
  #   volumes:
  #     - ./admin:/app/admin
  #   depends_on:
  #     - api
  #     - worker
  #     - web

  # live:
  #   build:
  #     context: .
  #     dockerfile: ./live/Dockerfile.dev
  #   restart: unless-stopped
  #   networks:
  #     - dev_env
  #   volumes:
  #     - ./live:/app/live
  #   depends_on:
  #     - api
  #     - worker
  #     - web

  api:
    build:
      context: ./apps/api
      dockerfile: Dockerfile.dev
      args:
        DOCKER_BUILDKIT: 1
    restart: unless-stopped
    networks:
      - dev_env
    volumes:
      - ./apps/api:/code
    command: ./bin/docker-entrypoint-api-local.sh
    env_file:
      - ./apps/api/.env
    depends_on:
      - plane-db
      - plane-redis
      - plane-mq
    ports:
      - "8000:8000"

  worker:
    build:
      context: ./apps/api
      dockerfile: Dockerfile.dev
      args:
        DOCKER_BUILDKIT: 1
    restart: unless-stopped
    networks:
      - dev_env
    volumes:
      - ./apps/api:/code
    command: ./bin/docker-entrypoint-worker.sh
    env_file:
      - ./apps/api/.env
    depends_on:
      - api
      - plane-db
      - plane-redis

  beat-worker:
    build:
      context: ./apps/api
      dockerfile: Dockerfile.dev
      args:
        DOCKER_BUILDKIT: 1
    restart: unless-stopped
    networks:
      - dev_env
    volumes:
      - ./apps/api:/code
    command: ./bin/docker-entrypoint-beat.sh
    env_file:
      - ./apps/api/.env
    depends_on:
      - api
      - plane-db
      - plane-redis

  migrator:
    build:
      context: ./apps/api
      dockerfile: Dockerfile.dev
      args:
        DOCKER_BUILDKIT: 1
    restart: "no"
    networks:
      - dev_env
    volumes:
      - ./apps/api:/code
    command: ./bin/docker-entrypoint-migrator.sh --settings=plane.settings.local
    env_file:
      - ./apps/api/.env
    depends_on:
      - plane-db
      - plane-redis

  # proxy:
  #   build:
  #     context: ./apps/proxy
  #     dockerfile: Dockerfile.ce
  #   restart: unless-stopped
  #   networks:
  #     - dev_env
  #   ports:
  #     - ${LISTEN_HTTP_PORT}:80
  #     - ${LISTEN_HTTPS_PORT}:443
  #   env_file:
  #     - .env
  #   environment:
  #     FILE_SIZE_LIMIT: ${FILE_SIZE_LIMIT:-5242880}
  #     BUCKET_NAME: ${AWS_S3_BUCKET_NAME:-uploads}
  #   depends_on:
  #     - api
  #     - web
  #     - space
  #     - admin

volumes:
  redisdata:
  uploads:
  pgdata:
  rabbitmq_data:

networks:
  dev_env:
    driver: bridge