[Django]-Mac: simplest way to safely serve a django app on port 80 for development

4👍

Since you mentioned you don’t want to run the Django server as root and you are on a mac, you could forward traffic from port 80 to port 8000:

sudo ipfw add 100 fwd 127.0.0.1,8000 tcp from any to any 80 in

and then run the Django server as a normal user (by default it serves on port 8000)

./manage.py runserver

To remove the port forwarding, run:

sudo ipfw flush

Leave a comment