Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CSRF verification failed. Request aborted. #17

Open
rngallen opened this issue Jun 9, 2024 · 0 comments
Open

CSRF verification failed. Request aborted. #17

rngallen opened this issue Jun 9, 2024 · 0 comments

Comments

@rngallen
Copy link

rngallen commented Jun 9, 2024

I used waitress with nginx everything works okay, but when I login to the app i got error CSRF verification failed. Request aborted.

site available configurations

# mysite_nginx.conf

server {
    # the port your site will be served on
    listen      82;
    server_name 172.30.1.196;
    charset     utf-8;

    # max upload size
    client_max_body_size 75M;   # adjust to taste
	
	location = /favicon.ico {
		alias C:/Apache24/htdocs/fuel/assets/favicon.ico;
		expires 7d; 
	}
	
	location = robots.txt {
		alias C:/Apache24/htdocs/fuel/frontend/templates/frontend/robortx.txt;
		expires 7d;
	}
    # Django media
    location /media  {
        alias C:/Apache24/htdocs/fuel/media;  # your Django project's media files - amend as required
    }
    # Django static
    location /static {
        alias C:/Apache24/htdocs/fuel/assets; # your Django project's static files - amend as required
        expires 7d; 
    }

    # Finally, send all non-media requests to the Django server.
    location / {
        proxy_pass http://127.0.0.1:92; # See output from runserver.py
		proxy_set_header Host $host; # send host header to django
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; # send client ip to django
        proxy_set_header X-Forwarded-Proto $scheme; # send protocal to django
        #proxy_redirect http://127.0.0.1:91
		
    }
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant