From 2a21529d2a66b967034a80acc52eabcfdc6a5826 Mon Sep 17 00:00:00 2001 From: KeironO Date: Wed, 12 Jan 2022 17:11:18 +0000 Subject: [PATCH 1/3] Added deployment documentation --- doc/deployment/external.rst | 32 +++++++++++++++++++++++++++++++- 1 file changed, 31 insertions(+), 1 deletion(-) diff --git a/doc/deployment/external.rst b/doc/deployment/external.rst index 39602f332..f6de8156c 100644 --- a/doc/deployment/external.rst +++ b/doc/deployment/external.rst @@ -163,4 +163,34 @@ Setting up your environment --------------------------- Now it's time to set up your environment. This is done by through the use of a -:code:`dotenv` file. \ No newline at end of file +:code:`dotenv` file. + +In the root directory of the project, you can find a :code:`.env.sample` file. It's strongly recommended that you use this as a starting point: + +:: + + cp .env.sample .env + +Inside of this file you will find a number of environment variables: + +* :code:`FLASK_CONFIG=` A choice between :code:`deployment` and :code:`production`. :code:`production` disables debugging and stops SQLAlchemy spamming the console. +* :code:`POSTGRES_USER=` The username of your PostgreSQL user. If you are using the :code:`docker-compose` file then this will be used within the :code:`db` container. +* :code:`POSTGRES_PASSWORD=`The password of your PostgreSQL user. If you are using the :code:`docker-compose` file then this will be used within the :code:`db` container. +* :code:`POSTGRES_HOST=`The database host address of your PostgreSQL server. If you are deploying the project through :code:`docker-compose` then ensure that the name matches what is found within the :code:`docker-compose.yml` file (this is usually :code:`db`). +* :code:`POSTGRES_DB=`The database name for of your PostgreSQL server. If you are deploying the project through :code:`docker-compose` then ensure that the name matches what is found within the :code:`docker-compose.yml` file (this is usually :code:`limbus`). +* :code:`SECRET_KEY=` A secret key to protect you against XSS. Please change this. +* :code:`WTF_CSRF_SECRET_KEY=` A secret key to protect forms against XSS. Please change this. +* :code:`DOCUMENT_DIRECTORY=` Where you want your encrypted document store to be located. If you are using the :code:`docker-compose` file, then please ensure that you mount your location appropriately. +* :code:`TEMPLATES_DIRECTORY=`Where you want your templates store to be located. If you are using the :code:`docker-compose` file, then please ensure that you mount your location appropriately. +* :code:`DEBUG=`If you require debug information. In most deployments this should be set to False. +* :code:`DOID_PATH=`Where you want your DOID file to be located. If you are using the :code:`docker-compose` file, then please ensure that you mount your location appropriately. + + +.. note:: + Please ensure that all secret keys and passwords are secure. + + +Do it for me +------------ + +No. \ No newline at end of file From 45a9cd67eca82783fb98da3be3e684ae98364657 Mon Sep 17 00:00:00 2001 From: KeironO Date: Wed, 12 Jan 2022 17:15:00 +0000 Subject: [PATCH 2/3] Typos --- doc/deployment/external.rst | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/doc/deployment/external.rst b/doc/deployment/external.rst index f6de8156c..ffb323051 100644 --- a/doc/deployment/external.rst +++ b/doc/deployment/external.rst @@ -181,9 +181,9 @@ Inside of this file you will find a number of environment variables: * :code:`SECRET_KEY=` A secret key to protect you against XSS. Please change this. * :code:`WTF_CSRF_SECRET_KEY=` A secret key to protect forms against XSS. Please change this. * :code:`DOCUMENT_DIRECTORY=` Where you want your encrypted document store to be located. If you are using the :code:`docker-compose` file, then please ensure that you mount your location appropriately. -* :code:`TEMPLATES_DIRECTORY=`Where you want your templates store to be located. If you are using the :code:`docker-compose` file, then please ensure that you mount your location appropriately. -* :code:`DEBUG=`If you require debug information. In most deployments this should be set to False. -* :code:`DOID_PATH=`Where you want your DOID file to be located. If you are using the :code:`docker-compose` file, then please ensure that you mount your location appropriately. +* :code:`TEMPLATES_DIRECTORY=` Where you want your templates store to be located. If you are using the :code:`docker-compose` file, then please ensure that you mount your location appropriately. +* :code:`DEBUG=` If you require debug information. In most deployments this should be set to False. +* :code:`DOID_PATH=` Where you want your DOID file to be located. If you are using the :code:`docker-compose` file, then please ensure that you mount your location appropriately. .. note:: From d6b54d0b0834d0c48aa211ebc51ab62471a3f7fd Mon Sep 17 00:00:00 2001 From: KeironO Date: Wed, 12 Jan 2022 17:15:22 +0000 Subject: [PATCH 3/3] Typos --- doc/deployment/external.rst | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/doc/deployment/external.rst b/doc/deployment/external.rst index ffb323051..94d8f83ff 100644 --- a/doc/deployment/external.rst +++ b/doc/deployment/external.rst @@ -175,9 +175,9 @@ Inside of this file you will find a number of environment variables: * :code:`FLASK_CONFIG=` A choice between :code:`deployment` and :code:`production`. :code:`production` disables debugging and stops SQLAlchemy spamming the console. * :code:`POSTGRES_USER=` The username of your PostgreSQL user. If you are using the :code:`docker-compose` file then this will be used within the :code:`db` container. -* :code:`POSTGRES_PASSWORD=`The password of your PostgreSQL user. If you are using the :code:`docker-compose` file then this will be used within the :code:`db` container. -* :code:`POSTGRES_HOST=`The database host address of your PostgreSQL server. If you are deploying the project through :code:`docker-compose` then ensure that the name matches what is found within the :code:`docker-compose.yml` file (this is usually :code:`db`). -* :code:`POSTGRES_DB=`The database name for of your PostgreSQL server. If you are deploying the project through :code:`docker-compose` then ensure that the name matches what is found within the :code:`docker-compose.yml` file (this is usually :code:`limbus`). +* :code:`POSTGRES_PASSWORD=` The password of your PostgreSQL user. If you are using the :code:`docker-compose` file then this will be used within the :code:`db` container. +* :code:`POSTGRES_HOST=` The database host address of your PostgreSQL server. If you are deploying the project through :code:`docker-compose` then ensure that the name matches what is found within the :code:`docker-compose.yml` file (this is usually :code:`db`). +* :code:`POSTGRES_DB=` The database name for of your PostgreSQL server. If you are deploying the project through :code:`docker-compose` then ensure that the name matches what is found within the :code:`docker-compose.yml` file (this is usually :code:`limbus`). * :code:`SECRET_KEY=` A secret key to protect you against XSS. Please change this. * :code:`WTF_CSRF_SECRET_KEY=` A secret key to protect forms against XSS. Please change this. * :code:`DOCUMENT_DIRECTORY=` Where you want your encrypted document store to be located. If you are using the :code:`docker-compose` file, then please ensure that you mount your location appropriately.