docker-compose.yaml 2.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465
  1. # This compose setup is only meant for local development of Misago itself
  2. # This is not for running your Misago site in docker
  3. version: "3.0"
  4. services:
  5. postgres:
  6. image: postgres:10
  7. environment:
  8. - POSTGRES_USER=misago
  9. - POSTGRES_PASSWORD=misago
  10. ports:
  11. - '127.0.0.1:5432:5432'
  12. redis:
  13. image: redis:5
  14. restart: unless-stopped
  15. misago:
  16. build: .
  17. command: python manage.py runserver 0.0.0.0:8000
  18. environment:
  19. # Postgres
  20. - POSTGRES_USER=misago
  21. - POSTGRES_PASSWORD=misago
  22. - POSTGRES_DB=misago
  23. - POSTGRES_HOST=postgres
  24. - POSTGRES_TEST_DB=misago_test
  25. # Superuser
  26. - SUPERUSER_USERNAME=Admin
  27. - SUPERUSER_EMAIL=admin@example.com
  28. - SUPERUSER_PASSWORD=password
  29. ports:
  30. # Map port 8000 in the container to port 8000 on the host
  31. # This way we can access the forum through http://localhost:8000
  32. - "${MISAGO_DEVSERVER_PORT:-8000}:8000"
  33. depends_on:
  34. - postgres
  35. tty: true
  36. volumes:
  37. # Map in the entire project into the container
  38. # This makes sure files in the container updates on the fly as we were working locally
  39. - .:/srv/misago:Z
  40. celery:
  41. build: .
  42. command: celery -A tasks worker --loglevel=info
  43. environment:
  44. # Postgres
  45. - POSTGRES_USER=misago
  46. - POSTGRES_PASSWORD=misago
  47. - POSTGRES_DB=misago
  48. - POSTGRES_HOST=postgres
  49. - POSTGRES_TEST_DB=misago_test
  50. # Superuser
  51. - SUPERUSER_USERNAME=Admin
  52. - SUPERUSER_EMAIL=admin@example.com
  53. - SUPERUSER_PASSWORD=password
  54. ports:
  55. # Map port 8000 in the container to port 8000 on the host
  56. # This way we can access the forum through http://localhost:8000
  57. - "${MISAGO_DEVSERVER_PORT:-8000}:8000"
  58. depends_on:
  59. - postgres
  60. tty: true
  61. volumes:
  62. # Map in the entire project into the container
  63. # This makes sure files in the container updates on the fly as we were working locally
  64. - .:/srv/misago:Z