Use repository root as build context in docker-compose

This fixes the issue where `docker-compose` fails to build takahe:latest container. The cause of issue is the build context for docker compose is different from the one of `docker build`. Currently, `make image` uses the repository root as a build context while `make compose_up` will use `docker/` directory as a build context. That's why docker-compose couldn't find the required files during building.
This commit is contained in:
TAKAHASHI Shuuji 2022-11-24 05:06:17 +09:00 committed by GitHub
parent 807d546b12
commit cb26d78d36
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -6,7 +6,10 @@ version: "3.4"
x-takahe-common:
&takahe-common
build: .
build:
context: ..
dockerfile: ./docker/Dockerfile
image: takahe:latest
environment:
DJANGO_SETTINGS_MODULE: takahe.settings.development