From ccefe5f792e861e62d1e97b86e1d3f8ab9a8daeb Mon Sep 17 00:00:00 2001 From: Andrew Hosgood Date: Wed, 4 Sep 2024 12:56:42 +0100 Subject: [PATCH] Add MKDocs --- Dockerfile | 3 +++ docker-compose.yml | 7 +++++++ docs/index.md | 1 + mkdocs.yml | 3 +++ 4 files changed, 14 insertions(+) create mode 100644 docs/index.md create mode 100644 mkdocs.yml diff --git a/Dockerfile b/Dockerfile index 60769a8..a130c17 100644 --- a/Dockerfile +++ b/Dockerfile @@ -15,5 +15,8 @@ RUN tna-build # Copy in the application code COPY --chown=app . . +# Delete tests and docs +RUN rm -fR /app/test /app/docs + # Run the application CMD ["tna-run", "-a", "fastapi_app:app"] diff --git a/docker-compose.yml b/docker-compose.yml index 4e20476..91e1250 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -17,3 +17,10 @@ services: image: ghcr.io/nationalarchives/tna-python-dev:preview volumes: - ./:/app + + docs: + image: squidfunk/mkdocs-material + volumes: + - .:/docs + ports: + - 1083:8000 diff --git a/docs/index.md b/docs/index.md new file mode 100644 index 0000000..dd6974f --- /dev/null +++ b/docs/index.md @@ -0,0 +1 @@ +# Welcome \ No newline at end of file diff --git a/mkdocs.yml b/mkdocs.yml new file mode 100644 index 0000000..d338ca4 --- /dev/null +++ b/mkdocs.yml @@ -0,0 +1,3 @@ +site_name: Flask Application Docs +repo_url: https://github.com/nationalarchives/flask-application-template +dev_addr: 0.0.0.0:1081