Docker Compose가 ml_backend 서비스를 빌드하면서 docker.io/library/python:3.11-slim 이미지를 Docker Hub에서 가져오던 중, 해당 작업이 취소(CANCELED) 되었다는 뜻이다. 일반적으로 이미지 메타데이터 로드가 실패하거나 중단된 경우 발생한다.
docker pull python:3.11-slim
명령어로 파이썬 이미지를 Docker Hub 에서 직접 땡겨옴
docker-compose build --no-cache
로 캐시를 지우고 다시 빌드
docker system prune -a
전체 docker 캐시 정리
docker-compose.yml
version: '3.8'
services:
myproject:
build:
context: <첫 번째 프로젝트 위치>
container_name: myproject # Name of the container for the first project
ports:
- "8000:8000" # Map port 8000 on the host to port 8000 in the container
volumes:
- <첫 번째 프로젝트 위치>:/app # Sync local project directory with the container
environment:
- DJANGO_SETTINGS_MODULE=myProject.settings # Specify Django settings module for the first project
ml_backend:
build:
context: <두 번째 프로젝트 위치> # Path to the second project's directory
container_name: ml_backend # Name of the container for the second project
ports:
- "8001:8001" # Map port 8001 on the host to port 8001 in the container
volumes:
- <두 번째 프로젝트 위치>:/app # Sync local project directory with the container
environment:
- DJANGO_SETTINGS_MODULE=ml.settings # Specify Django settings module for the second project