Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions fastapi-postgres/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,11 @@ RUN pip install --no-cache-dir -r requirements.txt
COPY . .

# Set environment variables for PostgreSQL
ENV POSTGRES_USER=postgres \
POSTGRES_PASSWORD=postgres \
POSTGRES_DB=studentdb \
POSTGRES_HOST=0.0.0.0 \
POSTGRES_PORT=5432
# ENV POSTGRES_USER=postgres \
# POSTGRES_PASSWORD=postgres \
# POSTGRES_DB=studentdb \
# POSTGRES_HOST=0.0.0.0 \
# POSTGRES_PORT=5432

# Install PostgreSQL client
RUN apt-get update && apt-get install -y postgresql-client
Expand All @@ -27,4 +27,4 @@ RUN apt-get update && apt-get install -y postgresql-client
EXPOSE 8000

# Start the FastAPI application
CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "8000"]
CMD ["uvicorn", "application.main:app", "--host", "0.0.0.0", "--port", "8000"]
Loading