Skip to content
Open
Show file tree
Hide file tree
Changes from 1 commit
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
14 changes: 14 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
ARG python_version=3.8
FROM python:${python_version}
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Missing multi-stage build: Requirement #3 explicitly requires a 'build stage and run stage' in the Dockerfile. Currently, there's only a single FROM instruction. A multi-stage Dockerfile should have at least two FROM statements - one for the build stage (installing dependencies, compiling) and one for the run stage (using a slim base image).

WORKDIR /app
# Спочатку копіюємо requirements.txt
COPY requirements.txt .
# Встановлюємо залежності
RUN pip install -r requirements.txt
# Копіюємо код проекту
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

INSTRUCTION.md is incomplete: The file is truncated and missing required sections. Per requirements #12 and #13, it must include: (1) instructions for running the container (docker run command), and (2) instructions for accessing the application via browser (e.g., http://localhost:8080).

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Missing push instructions: The INSTRUCTION.md should include instructions for pushing the image to Docker Hub with the 1.0.0 tag as per the task requirements.

COPY . .
# Тепер можна мігрувати
RUN python manage.py migrate
ENV PYTHONUNBUFFERED=1
EXPOSE 8080
CMD ["python", "manage.py", "runserver", "0.0.0.0:8080"]
7 changes: 7 additions & 0 deletions INSTRUCTION.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Django ToDo App
## Docker Hub
Comment on lines +1 to +2
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The Dockerfile must contain both a build stage and a run stage (multi-stage build) as required by task item #3. Currently, there's only a single FROM statement. Add a build stage (e.g., FROM python:3.8-slim AS builder) and a separate run stage (e.g., FROM python:3.8-slim) to copy only the necessary artifacts.

[Link to your Docker Hub repository](https://hub.docker.com/r/b1mb4/devops_todolist)
## Building and Running
### Build the image
```bash
docker build -t todoapp .
Comment on lines +1 to +7
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The INSTRUCTION.md file is incomplete. It's missing instructions for running the container and instructions for accessing the application via browser, which are required by task items #12 and #13. Add: 1) docker run -p 8080:8080 todoapp command, 2) Browser access instructions (e.g., http://localhost:8080 or http://0.0.0.0:8080)

Loading