From caa5d1b002ab21a4d5d0bd8ad98c54823f9be8a1 Mon Sep 17 00:00:00 2001 From: Samuel Cattini-Schultz Date: Wed, 24 Apr 2024 13:30:05 +1000 Subject: [PATCH] Dockerise docs site --- docker-compose.override.yml | 4 ++++ docker-compose.yml | 5 +++++ docs/.dockerignore | 1 + docs/Dockerfile | 17 +++++++++++++++++ 4 files changed, 27 insertions(+) create mode 100644 docs/.dockerignore create mode 100644 docs/Dockerfile diff --git a/docker-compose.override.yml b/docker-compose.override.yml index 9e9a7b5..6105afb 100644 --- a/docker-compose.override.yml +++ b/docker-compose.override.yml @@ -22,3 +22,7 @@ services: - 5003:80 environment: - ASPNETCORE_ENVIRONMENT=Development + + docs: + ports: + - 8000:8000 diff --git a/docker-compose.yml b/docker-compose.yml index b5a2390..28276b5 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -46,5 +46,10 @@ services: cache: image: redis:6 + docs: + build: ./docs + volumes: + - ./docs:/docs + volumes: beatmaps: diff --git a/docs/.dockerignore b/docs/.dockerignore new file mode 100644 index 0000000..21d0b89 --- /dev/null +++ b/docs/.dockerignore @@ -0,0 +1 @@ +.venv/ diff --git a/docs/Dockerfile b/docs/Dockerfile new file mode 100644 index 0000000..8e7299d --- /dev/null +++ b/docs/Dockerfile @@ -0,0 +1,17 @@ +FROM python:3.12-alpine3.19 + +RUN apk add --no-cache tini + +WORKDIR /docs + +COPY requirements.txt . + +RUN pip install --no-cache-dir -r requirements.txt + +COPY . . + +EXPOSE 8000 + +ENTRYPOINT [ "/sbin/tini", "--", "mkdocs" ] + +CMD [ "serve", "--dev-addr=0.0.0.0:8000"]