diff --git a/.devcontainer/api.dockerfile b/.devcontainer/api.dockerfile index c04a6056..8f77e09a 100644 --- a/.devcontainer/api.dockerfile +++ b/.devcontainer/api.dockerfile @@ -8,7 +8,7 @@ ENV VIRTUAL_ENV ${WORKSPACE_DIR}/api/tacticalrmm/env ENV PYTHONDONTWRITEBYTECODE=1 ENV PYTHONUNBUFFERED=1 -EXPOSE 8000 8383 +EXPOSE 8000 8383 8005 RUN groupadd -g 1000 tactical && \ useradd -u 1000 -g 1000 tactical diff --git a/.devcontainer/docker-compose.yml b/.devcontainer/docker-compose.yml index f9582f8a..84199f44 100644 --- a/.devcontainer/docker-compose.yml +++ b/.devcontainer/docker-compose.yml @@ -227,6 +227,21 @@ services: volumes: - tactical-data-dev:/opt/tactical + mkdocs-dev: + container_name: trmm-mkdocs-dev + image: api-dev + restart: always + build: + context: . + dockerfile: ./api.dockerfile + command: ["tactical-mkdocs-dev"] + ports: + - "8005:8005" + volumes: + - ..:/workspace:cached + networks: + - dev + volumes: tactical-data-dev: postgres-data-dev: diff --git a/.devcontainer/entrypoint.sh b/.devcontainer/entrypoint.sh index 0432c314..2760ef64 100644 --- a/.devcontainer/entrypoint.sh +++ b/.devcontainer/entrypoint.sh @@ -170,3 +170,8 @@ if [ "$1" = 'tactical-websockets-dev' ]; then check_tactical_ready "${VIRTUAL_ENV}"/bin/daphne tacticalrmm.asgi:application --port 8383 -b 0.0.0.0 fi + +if [ "$1" = 'tactical-mkdocs-dev' ]; then + cd "${WORKSPACE_DIR}/docs" + "${VIRTUAL_ENV}"/bin/mkdocs serve +fi