Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

319
Views
Getting 502 Bad Gateway while running the Django application within a docker container?

Those are the following steps I am following to run my application within a docker container .

docker run -i -t -d -p 8000:8000 c4ba9ec8e613 /bin/bash
docker attach c4ba9ec8e613

my start up script :

#!/bin/bash
#activate virtual env
echo Activate vitualenv.
source /home/my_env/bin/activate

#restart nginx
echo Restarting Nginx
service nginx restart

# Start Gunicorn processes
echo Starting Gunicorn.
gunicorn OPC.wsgi:application --bind=0.0.0.0:8000 --daemon

This setup is working fine in the local machine but not working within the docker .

over 4 years ago · Santiago Trujillo
1 answers
Answer question

0

Need to change the port no application to be accessible as my nginx server is responding at port 80

docker run -i -t -d -p 80:80 c4ba9ec8e613 /bin/bash
docker attach c4ba9ec8e613
over 4 years ago · Santiago Trujillo Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!