man im havin masalah yang sama; jadi saya melakukannya ... lihat menggunakan UWSGI + DJANGO + NGINX + REACT +
1 - nano /etc/uwsgi/sites/app_plataform.ini [uwsgi]
DJANGO_SETTINGS_MODULE = app_plataform.settings env = DJANGO_SETTINGS_MODULE pengaturan.configure ()
chdir = / home / app_plataform home = / root / app_plataform module = prometheus_plataform.wsgi: application
master = true proses = 33 ukuran buffer = 32768
socket = /home/app_plataform/app_plataform.sock chmod-socket = 777 vacuum = true
2 - melakukan peningkatan kinerja yang serius pada nginx ... pengguna www-data;
pekerja_proses otomatis; proses pekerja_ 4; pid /run/nginx.pid; termasuk /etc/nginx/modules-enabled/*.conf;
events {worker_connections 4092; multi_menerima pada; }
http {## UPGRADE CONFIGS
client_body_buffer_size 16K; client_header_buffer_size 16k; client_max_body_size 32m; #large_client_header_buffers 2 1k;
client_body_timeout 12; client_header_timeout 12; keepalive_timeout 15; send_timeout 10; access_log off;
## # Pengaturan dasar ##
sendfile aktif; tcp_nopush aktif; tcp_nodelay aktif; #keepalive_timeout 65; types_hash_max_size 2048; server_token off;
server_names_hash_bucket_size 64; # server_name_in_redirect mati;
termasuk /etc/nginx/mime.types; default_type application / octet-stream;
## # Pengaturan SSL ##
ssl_protocols TLSv1 TLSv1.1 TLSv1.2; # Menjatuhkan SSLv3, ref: POODLE ssl_prefer_server_ciphers aktif;
## # Pengaturan Logging ##
access_log /var/log/nginx/access.log; error_log /var/log/nginx/error.log;
## # Pengaturan Gzip ##
gzip aktif; gzip_comp_level 2; gzip_min_length 1000; gzip_proxied
kedaluwarsa no-cache no-store auth private; gzip_types teks / aplikasi biasa / x-javascript teks / xml teks / aplikasi css / xml; gzip_vary aktif;
#gzip_proxied any; #gzip_comp_level 6; gzip_buffers 16 8k; gzip_http_version 1.1; #gzip_types teks / teks biasa / aplikasi css / aplikasi json / teks javascript / aplikasi xml / aplikasi xml / xml + rss teks / javascript;
## # Konfigurasi Host Virtual ##
termasuk /etc/nginx/conf.d/ .conf ; termasuk / etc / nginx / situs-enabled / ; }
3 - lalu ... mulai ulang layanan atau masukkan kembali server ...
restart sistemctl uwsgi & systemctl restart nginx