This repository you can for any python django rest project. just add new app. We create this project by using django rest, postgresql, nginx and gunicorn
|
|--> example.env
|--> .env
POSTGRES_USER=postgres
POSTGRES_PASSWORD=postgres
POSTGRES_DB=blog
server_name www.example.com
proxy_set_header Host www.example.com;
- Docker Build
docker-compose up -d --build
- Let's Browse http://0.0.0.0:8086
- Migration and super user create
docker-compose exec web python manage.py migrate --noinput
docker-compose exec web python manage.py createsuperuser
- Collect Statics
docker-compose exec web python manage.py collectstatic --no-input --clear
- Check Logs
docker-compose logs -f
- Container down
docker-compose down
- Docker List Volume Mount
docker volume ls
- Docker Individual Volume
docker inspect $name