mirror of
https://github.com/minetest/contentdb.git
synced 2024-11-08 16:43:47 +01:00
Add celery support to docker config
This commit is contained in:
parent
a45df0e173
commit
7d52931a20
@ -1,4 +1,4 @@
|
||||
FROM python:3.7
|
||||
FROM python:3.6
|
||||
|
||||
WORKDIR /home/cdb
|
||||
|
||||
@ -14,6 +14,3 @@ COPY setup.py ./setup.py
|
||||
COPY app app
|
||||
COPY migrations migrations
|
||||
COPY config.prod.cfg ./config.prod.cfg
|
||||
|
||||
EXPOSE 5123
|
||||
ENTRYPOINT ["./runprodguni.sh"]
|
||||
|
@ -6,24 +6,31 @@ services:
|
||||
volumes:
|
||||
- "./data/db:/var/lib/postgresql/data"
|
||||
env_file:
|
||||
- db.env
|
||||
networks:
|
||||
- db_nw
|
||||
- config.env
|
||||
|
||||
redis:
|
||||
image: 'redis:3.0-alpine'
|
||||
command: redis-server
|
||||
volumes:
|
||||
- './data/redis:/data'
|
||||
|
||||
app:
|
||||
build: .
|
||||
command: ./runprodguni.sh
|
||||
ports:
|
||||
- 5123:5123
|
||||
volumes:
|
||||
- "./data/uploads:/home/app/public/uploads"
|
||||
networks:
|
||||
- db_nw
|
||||
- web_nw
|
||||
- "./data/uploads:/home/cdb/app/public/uploads"
|
||||
depends_on:
|
||||
- db
|
||||
- redis
|
||||
|
||||
networks:
|
||||
db_nw:
|
||||
driver: bridge
|
||||
web_nw:
|
||||
driver: bridge
|
||||
worker:
|
||||
build: .
|
||||
command: celery -A app.tasks.celery worker
|
||||
env_file:
|
||||
- config.env
|
||||
volumes:
|
||||
- "./data/uploads:/home/cdb/app/public/uploads"
|
||||
depends_on:
|
||||
- redis
|
||||
|
Loading…
Reference in New Issue
Block a user