Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3808468
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 19, 20262026-05-19T15:09:07+00:00 2026-05-19T15:09:07+00:00

I have a webapp built with Django. I’m currently running it off a laptop

  • 0

I have a webapp built with Django. I’m currently running it off a laptop at home behind a router.

I have the router configured to route all traffic sent to a specific port to that laptop.

I have Nginx as a reverse proxy for Apache, using mod_wsgi to run Django.

My problem is this: when I try to submit any POST form, the port # gets removed from the url (e.g. 209.245.23.201:1552/login/ becomes 209.245.23.201/login/)

Naturally, this breaks. What causes this (Nginx, Apache, Django?) and how can I fix it?

Thanks in advance.

EDIT: It appears that the forms DO submit, but I think the redirect fails.

EDIT 2: The problem is definitely either with Nginx, or the interaction between Nginx and Apache. I tried the setup with Apache as the only server, running django, and it worked fine. So either Nginx is dropping the port, or somehow Apache is getting confused by Nginx acting as the proxy.whatever

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-19T15:09:08+00:00Added an answer on May 19, 2026 at 3:09 pm

    I have the same problem with my development server.
    After some internet search I’ve found this discussion (nginx, apache, and odd admin error) where the solution is to modify the proxy configuration of nginx.

    The configuration setting to modify is:

    proxy_set_header            Host $host;
    

    the solution is to add the port number:

    proxy_set_header            Host $host:$server_port;
    

    In my ngnix + apache2 (with worker mpm) + django now all works well.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have inherited a webapp built using NetBean's internal ant. All jsps reside in:
I have a self built JSP webapp and at the moment I'm using tomcats
I'm running an Apache server (v2.2.10) with mod_python, Python 2.5 and Django. I have
I have a Sinatra webapp I've built using enable :sessions where I access my
I maintain a Django webapp for a client of mine. We built it out
I have a webapp, built with GWT (meaning its 100% ajax) and I want
I have a web app built against asp.net 2.0, but keep getting the following
I am a broke college student. I have built a small web app in
I have a webapp development problem that I've developed one solution for, but am
I have a webapp that I am in the middle of doing some load/performance

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.