Skip to main content
🔒 Preview mode. The first 15 Foundations lessons are free; this one is Pro. Start a 7-day trial to unlock the editor, AI hints and the rest of the curriculum. Card required, cancel any time in Dashboard.Start 7-day trial →
← CoursesDevOps for Python servicesModule 4 · Observability & LoggingMulti-stage Dockerfile with BuildKit cache mountspredict55 / 104
+110 XP
Task
📝 **Question:** Predict the cache status of layers 1..5 in the order they appear, as a Python list of `'CACHED'` / `'REBUILT'` strings. 📋 Pick the right answer. 💡 **Hint:** Re-read the theory above if unsure.
Predict the output

Read the code carefully

# Dockerfile (recap of the 5 layers):
#   1: FROM python:3.13-slim AS builder
#   2: WORKDIR /app
#   3: COPY pyproject.toml uv.lock ./
#   4: RUN --mount=type=cache,... pip install uv && uv sync --frozen --no-dev
#   5: COPY src/ ./src/
#
# Commit under test: only `src/handlers.py` changed.
# Prior CI build populated the layer cache one commit ago.
#
# For each layer 1..5, decide 'CACHED' or 'REBUILT' in order, as a Python
# list of strings.
#
# What does the predicted list look like? Type your prediction.

What will the program print? Write here:

💬 Discussion

Be the first to ask a question or share a tip.
Sign in to join the discussion. Reading is free.
Loading discussion…