when i get the object in django rest framework urls always comes absolute with localhost, but when creating im proxy on nginx is there any way to set this url in settings
Example
count: 11 next: "http://localhost:8000/api/accounts/?ordering=-date_registered&page=2" previous: null
I need it to be
count: 11 next: "http:/example.com/api/accounts/?ordering=-date_registered&page=2" previous: null
---------- edit --------------------------
see my full nginx configuration
server { listen 80; server_name 123.123.123.123; root /home/admin/www/site-web/dist; index index.html; charset utf-8; location /static/ { alias /home/admin/www/site/static/; } location /media/ { alias /home/admin/www/site/media/; } location /nginx_status/ {
==== super edit ====
Sorry guys, I had "underscores_in_headers"; I deleted it and everything works
=================
source share