79809389

Date: 2025-11-04 20:57:45
Score: 1
Natty:
Report link

MOHAMED.

// Source - Why am I getting "ERR_CONNECTION_REFUSED" when querying by sidecar-hosted backend in Azure App Service?

// Posted by chris

// Retrieved 11/4/2025, License - CC-BY-SA 4.0

FROM python:3.10-slim

RUN mkdir /backend

WORKDIR /backend

ENV PYTHONDONTWRITEBYTECODE=1

ENV PYTHONUNBUFFERED = 1

RUN pip install --upgrade pip --trusted-host pypi.org

COPY requirements.txt /backend/

RUN apt-get update && \

apt-get install -y libpq-dev gcc

RUN pip install --no-cache-dir -r requirements.txt --trusted-host pypi.org

COPY . /backend/

EXPOSE 8080 80

CMD ["daphne", "-b", "0.0.0.0", "-p", "8080", "backend.asgi:application"]

Reasons:
  • Contains signature (1):
  • Long answer (-0.5):
  • Has code block (-0.5):
  • Low reputation (1):
Posted by: MOHAMED