Can`t verify the email address with Django Rest and React

131 views Asked by At

friend, I'm new and trying to figure it out. I have some problems with verification user via email. I have backend on 8000 port with Django rest framework and frontend on 3000 port with React. After registration I receive an email with link to submit email, like this: http://localhost:8000/activate/NDQ/b87jb3-6f86c3a304f606f584203f4d4e5ecfe8 If I click on this link, I receive an error Page not found (404). But if I change in address string Port on 3000: http://localhost:3000/activate/NDQ/b87jb3-6f86c3a304f606f584203f4d4e5ecfe8 verification submit and have no problem. What do I need to do to get verification through the link that comes in the letter, because there is port 8000, and the frontend has 3000

1

There are 1 answers

0
Franco Ball On

I suppose you are working with Djoser. What you need to do in order to change the localhost port sent in the email is to add this to your settings.py file in your Django project

DOMAIN = 'localhost:3000'