Skip to content

Commit 8b15c56

Browse files
committed
Clean runtime files, harden settings, and update dependencies
1 parent 4bef603 commit 8b15c56

5 files changed

Lines changed: 47 additions & 15 deletions

File tree

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,21 @@
11
#Django
2-
SECRET_KEY="VvtB8aE9k#3K6&x5GXjbNrFzdJcP@Q_gy4UDDbT9zLgACGP$KZpuk-M7aHRd4U@yrj6ht#VX"
2+
SECRET_KEY="change-me"
33
DJANGO_SU_NAME=admin
44
DJANGO_SU_EMAIL=admin@example.com
5-
DJANGO_SU_PASSWORD=P@ssw0rd
5+
DJANGO_SU_PASSWORD=change-me
66
TIME_ZONE=Europe/Istanbul
77
DIRPATH=/opt/mt_queue_mgr
88
FW_ADDRESS_LIST=NoFastTrack
99
# LOG_LEVEL options. Possible values are: DEBUG, INFO, WARNING, ERROR, CRITICAL
1010
LOG_LEVEL=WARNING
11+
1112
# Database options:
12-
# Replace with the IP address of your mySQL host
13+
# Replace with the IP address of your mySQL host or container name
1314
DATABASE_HOST=172.20.0.4
1415
# Replace with the name of the database you created for this app
1516
DATABASE_NAME=queues
1617
# Replace with the user name for your database access
17-
DATABASE_USER=admin
18+
DATABASE_USER=queues_mgr
1819
# Replace with the password name for your database access
19-
DATABASE_PASSWORD=VvtB8aE9k3K6!x5@
20+
DATABASE_PASSWORD=change-me
2021
DATABASE_CHARSET=utf8

.gitignore

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
# Secrets / environment
2+
.env
3+
.env.*
4+
!.env.example
5+
6+
# Runtime data
7+
db.sqlite3
8+
*.sqlite3
9+
log/*
10+
!log/.gitkeep
11+
logs/
12+
*.log
13+
*.log.*
14+
15+
# Django generated/static runtime output
16+
static/
17+
media/
18+
19+
# Python
20+
__pycache__/
21+
*.py[cod]
22+
*.pyo
23+
*.pyd
24+
.pytest_cache/
25+
.mypy_cache/
26+
.ruff_cache/
27+
28+
# OS/editor
29+
.DS_Store
30+
.vscode/
31+
.idea/

core/limiter.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ def __init__(self, ip, username, password):
2828
def _test_socket(self):
2929
""" Connect to router's API """
3030
sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
31-
sock.settimeout(2)
31+
sock.settimeout(5)
3232
result = sock.connect_ex((self._ip,8728))
3333
if result == 0:
3434
self._sock_ok = True
File renamed without changes.

requirements.txt

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
asgiref==3.8.1
2-
Django==5.1.3
3-
django-log-viewer==1.1.7
4-
gunicorn==23.0.0
5-
mysqlclient==2.2.4
6-
python-dotenv==1.0.1
7-
RouterOS-api==0.18.1
8-
sqlparse==0.5.2
9-
tzdata==2024.2
1+
asgiref==3.11.1
2+
Django>=5.2,<5.3
3+
django-log-viewer==1.1.8
4+
gunicorn==26.0.0
5+
mysqlclient==2.2.8
6+
python-dotenv==1.2.2
7+
RouterOS-api==0.21.0
8+
sqlparse==0.5.5
9+
tzdata==2026.2

0 commit comments

Comments
 (0)