dj chat
1.0.0
Endereço do projeto Referência: http://106.55.162.109:8888/ Conta: Admin Senha: Xhongc
python manage.py runserver 8088 ou daphne -b 127.0.0.1 -p 8088 dj_chat.asgi:applicationnginx + daphne + gunicorn + supervisor
Dicas: Gunicorn e Daphne abrem portas diferentes!
server {
listen 80 ;
server_name 106.55.162.109 ;
charset utf-8;
client_max_body_size 75M ;
location /static {
alias /home/ubuntu/dj-chat/static;
}
access_log /home/ubuntu/chat_log/access.log;
error_log /home/ubuntu/chat_log/error.log;
location / {
proxy_pass http://127.0.0.1:8000;
include /etc/nginx/uwsgi_params;
}
location /ws {
proxy_pass http://127.0.0.1:8001;
proxy_http_version 1.1 ;
proxy_set_header Upgrade $http_upgrade ;
proxy_set_header Connection "upgrade" ;
proxy_redirect off ;
proxy_set_header Host $host ;
proxy_set_header X-Real-IP $remote_addr ;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for ;
proxy_set_header X-Forwarded-Host $server_name ;
proxy_read_timeout 36000s ;
proxy_send_timeout 36000s ;
}
root /var/www/html;
index boot_chat.html;
}
docker-compose build
docker-compose up -dSaltos detalhados do processo para o aplicativo de implantação do docker django+daphne+gunicorn+nginx+redis