Skip to content
Snippets Groups Projects
Verified Commit 7f68252c authored by TheJoeCoder's avatar TheJoeCoder
Browse files

Create demo docker compose

parent 8c5d66cb
Branches
No related tags found
No related merge requests found
services:
web:
build: .
command: gunicorn heyheyLibrary.wsgi:application --bind 0.0.0.0:8000
environment:
- DJANGO_ALLOWED_HOSTS=librarydemo.rb9.xyz
- OPENSEARCH_USERNAME=admin
- OPENSEARCH_PASSWORD=VeryInsecurePassword1!
volumes:
- demo_static:/home/app/web/staticfiles
- demo_media:/home/app/web/mediafiles
- ./db.sqlite3:/home/app/web/db.sqlite3
expose:
- 8000
depends_on:
- opensearch
networks:
- librarydemo
opensearch:
image: opensearchproject/opensearch:latest
ulimits:
memlock:
soft: -1 # Set memlock to unlimited (no soft or hard limit)
hard: -1
nofile:
soft: 65536 # Maximum number of open files for the opensearch user - set to at least 65536
hard: 65536
volumes:
- demo_opensearch:/usr/share/opensearch/data # Creates volume called opensearch-data1 and mounts it to the container
expose:
- 9200
- 9600
networks:
- librarydemo
nginx:
image: nginx:1.27
volumes:
- ./nginx.conf:/etc/nginx/nginx.conf:ro
- demo_static:/home/app/web/staticfiles
- demo_media:/home/app/web/mediafiles
ports:
- 1337:80
depends_on:
- web
networks:
- librarydemo
volumes:
demo_static:
demo_media:
demo_opensearch:
networks:
librarydemo:
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment