From f5f4a33e8d7d30f480d37d81481611c32a4f29a2 Mon Sep 17 00:00:00 2001 From: InviteMe Developer Date: Mon, 31 Aug 2026 17:51:37 +0300 Subject: [PATCH] =?UTF-8?q?=D0=91=D0=B5=D0=B7=D0=BE=D0=BF=D0=B0=D1=81?= =?UTF-8?q?=D0=BD=D0=BE=D1=81=D1=82=D1=8C=20=D0=B8=20=D0=BF=D1=83=D0=B1?= =?UTF-8?q?=D0=BB=D0=B8=D0=BA=D0=B0=D1=86=D0=B8=D1=8F:=20=D1=83=D0=B1?= =?UTF-8?q?=D1=80=D0=B0=D0=BD=D1=8B=20=D0=BA=D0=BE=D1=80=D0=BF=D0=BE=D1=80?= =?UTF-8?q?=D0=B0=D1=82=D0=B8=D0=B2=D0=BD=D1=8B=D0=B5=20=D1=81=D0=BB=D0=B5?= =?UTF-8?q?=D0=B4=D1=8B,=20=D0=B8=D1=81=D0=BF=D1=80=D0=B0=D0=B2=D0=BB?= =?UTF-8?q?=D0=B5=D0=BD=D1=8B=20=D0=B7=D0=B0=D0=B2=D0=B8=D1=81=D0=B8=D0=BC?= =?UTF-8?q?=D0=BE=D1=81=D1=82=D0=B8,=20SECRET=5FKEY=20=D0=BE=D0=B1=D1=8F?= =?UTF-8?q?=D0=B7=D0=B0=D1=82=D0=B5=D0=BB=D0=B5=D0=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .env.example | 2 +- LICENSE | 20 ++++++++++++++++++++ README.md | 6 +++--- app/__init__.py | 7 +++++++ app/templates/admin/email_settings.html | 4 ++-- app/templates/base.html | 5 ----- config.py | 2 +- docker-compose.yml | 4 ++-- requirements.txt | 8 ++++---- run.py | 3 ++- 10 files changed, 42 insertions(+), 19 deletions(-) create mode 100644 LICENSE diff --git a/.env.example b/.env.example index ba7b43e..a912b2c 100644 --- a/.env.example +++ b/.env.example @@ -2,7 +2,7 @@ # Обязательно: сильный случайный секретный ключ # Пример генерации: openssl rand -hex 32 -SECRET_KEY=change-me-in-production +SECRET_KEY= # Базовый URL приложения (без слэша в конце), используется в QR-кодах BASE_URL=https://your-domain.example.com diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..e3086f6 --- /dev/null +++ b/LICENSE @@ -0,0 +1,20 @@ +Proprietary License + +Copyright (c) 2026 InviteMe + +All rights reserved. + +This software and associated documentation files (the "Software") are the +proprietary and confidential information of InviteMe. The Software is protected +by copyright law and international treaties. + +Unauthorized access, use, copying, modification, merger, publication, +distribution, sublicensing, sale, transfer, reverse engineering, decompilation, +or disassembly of the Software, in whole or in part, is strictly prohibited +without prior written permission from the copyright holder. + +The Software is provided "AS IS", without warranty of any kind, express or +implied, including but not limited to the warranties of merchantability, +fitness for a particular purpose and noninfringement. + +For licensing inquiries, please contact the copyright holder. diff --git a/README.md b/README.md index 797d4fe..35f7ab8 100644 --- a/README.md +++ b/README.md @@ -21,7 +21,7 @@ Требования: установленный Docker и Docker Compose. ```bash -git clone https://git.mycloud24.ru/insight/InviteMe.git +git clone cd InviteMe # Собрать и запустить @@ -37,7 +37,7 @@ docker compose up -d --build Требования: Python 3.12. ```bash -git clone https://git.mycloud24.ru/insight/InviteMe.git +git clone cd InviteMe python -m venv venv @@ -101,4 +101,4 @@ InviteMe/ ## Лицензия -Проект распространяется как есть для внутреннего использования. +См. файл [LICENSE](LICENSE). diff --git a/app/__init__.py b/app/__init__.py index a5b0afb..4a7c02f 100644 --- a/app/__init__.py +++ b/app/__init__.py @@ -20,6 +20,13 @@ def create_app(config_class=Config): app = Flask(__name__) app.config.from_object(config_class) + secret_key = app.config.get("SECRET_KEY", "") + if not secret_key or secret_key == "change-me-in-production": + raise RuntimeError( + "SECRET_KEY не задан или равен значению по умолчанию. " + "Задайте уникальный секретный ключ через переменную окружения SECRET_KEY или файл .env." + ) + # Ensure upload directories exist os.makedirs(app.config["PHOTO_FOLDER"], exist_ok=True) os.makedirs(app.config["QR_FOLDER"], exist_ok=True) diff --git a/app/templates/admin/email_settings.html b/app/templates/admin/email_settings.html index 1f3325a..2ec9306 100644 --- a/app/templates/admin/email_settings.html +++ b/app/templates/admin/email_settings.html @@ -68,7 +68,7 @@
-
URL вида https://mail.integrita.ru/EWS/Exchange.asmx
+
URL вида https://mail.company.com/EWS/Exchange.asmx
@@ -88,7 +88,7 @@
- +
diff --git a/app/templates/base.html b/app/templates/base.html index e07a339..f21a477 100644 --- a/app/templates/base.html +++ b/app/templates/base.html @@ -7,7 +7,6 @@ -