Guest User

Untitled

a guest
Mar 22nd, 2019
52
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.61 KB | None | 0 0
  1. version: "3"
  2. services:
  3. web:
  4. image: project
  5. restart: always
  6. command: gunicorn conf.wsgi:application -c /opt/project/tools/docker/provision/gunicorn/production.py
  7. expose:
  8. - "8000"
  9. volumes:
  10. - .:/opt/project
  11. - ./media-volume:/var/www/media
  12. extra_hosts:
  13. - "database:${HOST_IP}" #To connect database server inside the container
  14. worker:
  15. image: project
  16. restart: always
  17. command: supervisord -c /opt/project/tools/docker/provision/supervisor/supervisord.conf
  18. volumes:
  19. - .:/opt/project
  20. - ./supervisor-volume/log:/var/log/supervisor/
  21. - ./media-volume:/var/www/media
  22. expose:
  23. - "9001"
  24. extra_hosts:
  25. - "database:${HOST_IP}" #To connect database server inside the container
  26. environment:
  27. SUPERVISOR_USER: ############
  28. SUPERVISOR_PASSWORD: ##########
  29. DJANGO_CONFIGURATION: conf.settings.prod
  30. depends_on:
  31. - web
  32. redis:
  33. restart: always
  34. image: redis:alpine
  35. expose:
  36. - "6379"
  37. volumes:
  38. - ./redis-volume/data:/data
  39. nginx:
  40. image: "nginx"
  41. restart: always
  42. environment:
  43. WEB_PORT: 80
  44. WEB_VIRTUAL_HOST: example.com
  45. PORTAINER_PORT: 80
  46. PORTAINER_VIRTUAL_HOST: portainer.example.com
  47. ADMINER_PORT: 80
  48. ADMINER_VIRTUAL_HOST: adminer.example.com
  49. SUPERVISOR_PORT: 80
  50. SUPERVISOR_VIRTUAL_HOST: supervisor.example.com
  51. PROXY_L_PORT: 80
  52. PROXY_L_VIRTUAL_HOST: proxy.example.com
  53. CERTIFICATE_PATH: /etc/letsencrypt/live/example.com/fullchain.pem
  54. CERTIFICATE_KEY_PATH: /etc/letsencrypt/live/example.com/privkey.pem
  55. command: /bin/bash -c "envsubst '$$WEB_PORT $$WEB_VIRTUAL_HOST $$PORTAINER_PORT $$PORTAINER_VIRTUAL_HOST $$ADMINER_PORT $$ADMINER_VIRTUAL_HOST $$SUPERVISOR_PORT $$SUPERVISOR_VIRTUAL_HOST $$PROXY_L_PORT $$PROXY_L_VIRTUAL_HOST $$CERTIFICATE_PATH $$CERTIFICATE_KEY_PATH' < /etc/nginx/conf.d/default.template > /etc/nginx/conf.d/default.conf && exec nginx -g 'daemon off;'"
  56. volumes:
  57. - ./tools/docker/provision/nginx:/etc/nginx/conf.d
  58. - ./static:/static
  59. - ./media-volume:/media:ro
  60. - ./letsencrypt-etc-volume:/etc/letsencrypt
  61. ports:
  62. - "80:80"
  63. - "443:443"
  64. portainer:
  65. image: portainer/portainer
  66. restart: always
  67. command: -H unix:///var/run/docker.sock --admin-password "#############"
  68. expose:
  69. - "9000"
  70. volumes:
  71. - /var/run/docker.sock:/var/run/docker.sock
  72. - ./portainer-volume:/data
  73. adminer:
  74. image: edyan/adminer
  75. restart: always
  76. environment:
  77. - ADMINER_VERSION=4.6.3
  78. expose:
  79. - "80"
  80. extra_hosts:
  81. - "database:${HOST_IP}" #To connect database server inside the container
  82. datadog:
  83. image: datadog/agent:latest
  84. restart: always
  85. environment:
  86. DD_API_KEY: #################################
  87. DD_LOGS_ENABLED: "true"
  88. DD_LOGS_CONFIG_CONTAINER_COLLECT_ALL : "true"
  89. DD_AC_EXCLUDE: "name:datadog-agent"
  90. volumes:
  91. - /var/run/docker.sock:/var/run/docker.sock
  92. - /proc/:/host/proc/:ro
  93. - /sys/fs/cgroup/:/host/sys/fs/cgroup:ro
  94. - ./datadog-agent-volume/run:/opt/datadog-agent/run:rw
  95. proxy:
  96. image: luminati/luminati-proxy:latest
  97. restart: always
  98. expose:
  99. - "22999"
  100. - "22555"
  101. - "24000"
  102. environment:
  103. LPM_CUSTOMER: #####
  104. LPM_ZONE: static
  105. LPM_PASSWORD: #####
  106. LPM_PROXY_PORT: 22225
  107. LPM_WWW_WHITELIST_IPS: "#.#.#.#/#"
  108. LPM_SSL: "true"
  109. LPM_CONFIG: "/etc/luminati/luminati.json"
  110. LPM_DATABASE: "/root/luminati-logs.sqlite3"
  111. command: ["luminati"]
  112. volumes:
  113. - ./tools/docker/provision/luminati:/etc/luminati/
  114. - ./luminati-volume:/root/
Add Comment
Please, Sign In to add comment