From d769481848d43114ac1e1a55ae000a5eb30a91b1 Mon Sep 17 00:00:00 2001 From: Benjamin Bach Date: Sat, 20 Jul 2024 22:33:30 +0200 Subject: [PATCH] Add a few more README things on Docker --- Makefile | 5 ++--- README.md | 13 +++++++++++++ 2 files changed, 15 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index de5cae6..651ed32 100644 --- a/Makefile +++ b/Makefile @@ -1,6 +1,5 @@ DOCKER_COMPOSE = COMPOSE_DOCKER_CLI_BUILD=1 DOCKER_BUILDKIT=1 docker compose DOCKER_RUN = ${DOCKER_COMPOSE} run -u `id -u` -DOCKER_CONTAINER_NAME = backend MANAGE_EXEC = python /app/src/manage.py MANAGE_COMMAND = ${DOCKER_RUN} app ${MANAGE_EXEC} @@ -28,5 +27,5 @@ shell: manage_command: ${MANAGE_COMMAND} ${ARGS} -build_dev_docker_image: - ${DOCKER_COMPOSE} build ${DOCKER_CONTAINER_NAME} +build: + ${DOCKER_COMPOSE} build diff --git a/README.md b/README.md index 65b41b1..41ef329 100644 --- a/README.md +++ b/README.md @@ -40,6 +40,19 @@ Working with the Docker Compose setup is made easy with the `Makefile` provided make run ``` +#### Building and running other things + +```bash +# Build the containers +make build + +# Create a superuser +make createsuperuser + +# Create Django migrations (after this, maybe you need to change file permissions in volume) +make makemigrations +``` + ### Using hatch #### Requirements