From b0c45224f128eeb44426a67f31cbfe35ff61818b Mon Sep 17 00:00:00 2001 From: Bruno Alla Date: Sat, 5 Oct 2024 11:29:57 -0300 Subject: [PATCH] Group docs into sections (#5426) --- .../project-generation-options.rst | 0 docs/{ => 1-getting-started}/settings.rst | 0 .../developing-locally-docker.rst | 42 ++++++------- .../developing-locally.rst | 5 +- .../generate-project-block.rst | 0 .../deployment-on-heroku.rst | 0 .../deployment-on-pythonanywhere.rst | 0 .../deployment-with-docker.rst | 0 docs/{ => 3-deployment}/mailgun.rst | 0 .../docker-postgres-backups.rst | 0 docs/{ => 4-guides}/document.rst | 0 docs/{ => 4-guides}/linters.rst | 0 docs/{ => 4-guides}/testing.rst | 0 docs/{ => 4-guides}/websocket.rst | 0 docs/{ => 5-help}/faq.rst | 0 docs/{ => 5-help}/troubleshooting.rst | 0 docs/6-about/contributing.md | 3 + docs/{ => 6-about}/maintainer-guide.md | 0 docs/contributing.md | 3 - docs/index.rst | 59 +++++++++++++------ 20 files changed, 67 insertions(+), 45 deletions(-) rename docs/{ => 1-getting-started}/project-generation-options.rst (100%) rename docs/{ => 1-getting-started}/settings.rst (100%) rename docs/{ => 2-local-development}/developing-locally-docker.rst (91%) rename docs/{ => 2-local-development}/developing-locally.rst (98%) rename docs/{ => 2-local-development}/generate-project-block.rst (100%) rename docs/{ => 3-deployment}/deployment-on-heroku.rst (100%) rename docs/{ => 3-deployment}/deployment-on-pythonanywhere.rst (100%) rename docs/{ => 3-deployment}/deployment-with-docker.rst (100%) rename docs/{ => 3-deployment}/mailgun.rst (100%) rename docs/{ => 4-guides}/docker-postgres-backups.rst (100%) rename docs/{ => 4-guides}/document.rst (100%) rename docs/{ => 4-guides}/linters.rst (100%) rename docs/{ => 4-guides}/testing.rst (100%) rename docs/{ => 4-guides}/websocket.rst (100%) rename docs/{ => 5-help}/faq.rst (100%) rename docs/{ => 5-help}/troubleshooting.rst (100%) create mode 100644 docs/6-about/contributing.md rename docs/{ => 6-about}/maintainer-guide.md (100%) delete mode 100644 docs/contributing.md diff --git a/docs/project-generation-options.rst b/docs/1-getting-started/project-generation-options.rst similarity index 100% rename from docs/project-generation-options.rst rename to docs/1-getting-started/project-generation-options.rst diff --git a/docs/settings.rst b/docs/1-getting-started/settings.rst similarity index 100% rename from docs/settings.rst rename to docs/1-getting-started/settings.rst diff --git a/docs/developing-locally-docker.rst b/docs/2-local-development/developing-locally-docker.rst similarity index 91% rename from docs/developing-locally-docker.rst rename to docs/2-local-development/developing-locally-docker.rst index cb2cdc0e..05e188e5 100644 --- a/docs/developing-locally-docker.rst +++ b/docs/2-local-development/developing-locally-docker.rst @@ -257,7 +257,7 @@ Here is a link to an article on `how to add HTTPS using Nginx`_ to your local do Webpack ~~~~~~~ -If you are using Webpack, first install ``mkcert``_. It is a simple by design tool that hides all the arcane knowledge required to generate valid TLS certificates. It works for any hostname or IP, including localhost. It supports macOS, Linux, and Windows, and Firefox, Chrome and Java. It even works on mobile devices with a couple manual steps. See https://blog.filippo.io/mkcert-valid-https-certificates-for-localhost/ +If you are using Webpack, first install `mkcert`_. It is a simple by design tool that hides all the arcane knowledge required to generate valid TLS certificates. It works for any hostname or IP, including localhost. It supports macOS, Linux, and Windows, and Firefox, Chrome and Java. It even works on mobile devices with a couple manual steps. See https://blog.filippo.io/mkcert-valid-https-certificates-for-localhost/ .. _`mkcert`: https://github.com/FiloSottile/mkcert/blob/master/README.md#supported-root-stores @@ -267,36 +267,36 @@ Assuming that you registered your local hostname as ``my-dev-env.local``, the ce 1. Add the ``nginx-proxy`` service to the ``docker-compose.local.yml``. :: - nginx-proxy: - image: jwilder/nginx-proxy:alpine - container_name: nginx-proxy - ports: - - "80:80" - - "443:443" - volumes: - - /var/run/docker.sock:/tmp/docker.sock:ro - - ./certs:/etc/nginx/certs - restart: always - depends_on: - - node - environment: - - VIRTUAL_HOST=my-dev-env.local - - VIRTUAL_PORT=3000 + nginx-proxy: + image: jwilder/nginx-proxy:alpine + container_name: nginx-proxy + ports: + - "80:80" + - "443:443" + volumes: + - /var/run/docker.sock:/tmp/docker.sock:ro + - ./certs:/etc/nginx/certs + restart: always + depends_on: + - node + environment: + - VIRTUAL_HOST=my-dev-env.local + - VIRTUAL_PORT=3000 2. Add the local secure domain to the ``config/settings/local.py``. You should allow the new hostname :: - ALLOWED_HOSTS = ["localhost", "0.0.0.0", "127.0.0.1", "my-dev-env.local"] + ALLOWED_HOSTS = ["localhost", "0.0.0.0", "127.0.0.1", "my-dev-env.local"] 3. Add the following configuration to the ``devServer`` section of ``webpack/dev.config.js`` :: - client: { - webSocketURL: 'auto://0.0.0.0:0/ws', // note the `:0` after `0.0.0.0` - }, + client: { + webSocketURL: 'auto://0.0.0.0:0/ws', // note the `:0` after `0.0.0.0` + }, Rebuild your ``docker`` application. :: - $ docker compose -f docker-compose.local.yml up -d --build + $ docker compose -f docker-compose.local.yml up -d --build Go to your browser and type in your URL bar ``https://my-dev-env.local``. diff --git a/docs/developing-locally.rst b/docs/2-local-development/developing-locally.rst similarity index 98% rename from docs/developing-locally.rst rename to docs/2-local-development/developing-locally.rst index 16247d08..11343e15 100644 --- a/docs/developing-locally.rst +++ b/docs/2-local-development/developing-locally.rst @@ -24,8 +24,7 @@ First things first. $ source /bin/activate -#. - .. include:: generate-project-block.rst +#. .. include:: generate-project-block.rst #. Install development requirements: :: @@ -219,7 +218,7 @@ The project comes with a simple task for manual testing purposes, inside `