mirror of
https://github.com/marcogll/telegram_new_socias.git
synced 2026-01-13 13:15:16 +00:00
feat: Dockerize application and add MySQL logging
This commit introduces Docker and Docker Compose to containerize the application and orchestrate it with a MySQL database. Key changes include: - Added a `Dockerfile` to create a container for the Python bot. - Created a `docker-compose.yml` file to manage the bot and MySQL services. - Added a `modules/database.py` module to handle database connections and logging with SQLAlchemy. - Integrated request logging into all command handlers. - Updated `requirements.txt` with necessary dependencies for MySQL. - Updated `.env` and `.gitignore` to manage database credentials securely. - Updated `Readme.md` with instructions on how to run the application using Docker Compose.
This commit is contained in:
93
.gitignore
vendored
93
.gitignore
vendored
@@ -1,61 +1,46 @@
|
||||
# =========================
|
||||
# Secrets & Environment
|
||||
# =========================
|
||||
# Environments
|
||||
.env
|
||||
.env.*
|
||||
*.env
|
||||
|
||||
# =========================
|
||||
# Python
|
||||
# =========================
|
||||
__pycache__/
|
||||
*.py[cod]
|
||||
*.pyo
|
||||
*.pyd
|
||||
|
||||
# Virtual environments
|
||||
venv/
|
||||
.venv/
|
||||
env/
|
||||
ENV/
|
||||
|
||||
# =========================
|
||||
# Logs & Runtime
|
||||
# =========================
|
||||
*.log
|
||||
logs/
|
||||
*.sqlite
|
||||
*.db
|
||||
|
||||
# =========================
|
||||
# OS & Editors
|
||||
# =========================
|
||||
.DS_Store
|
||||
Thumbs.db
|
||||
|
||||
# VS Code
|
||||
.vscode/
|
||||
*.code-workspace
|
||||
|
||||
# JetBrains
|
||||
.idea/
|
||||
|
||||
# =========================
|
||||
# Build / Distribution
|
||||
# =========================
|
||||
# Byte-compiled / optimized / C extensions
|
||||
__pycache__/
|
||||
*.py[cod]
|
||||
*$py.class
|
||||
|
||||
# Distribution / packaging
|
||||
.Python
|
||||
build/
|
||||
develop-eggs/
|
||||
dist/
|
||||
*.egg-info/
|
||||
|
||||
# =========================
|
||||
# Systemd / Deploy Artifacts
|
||||
# =========================
|
||||
*.service
|
||||
*.pid
|
||||
|
||||
# =========================
|
||||
# Temp / Downloads
|
||||
# =========================
|
||||
tmp/
|
||||
temp/
|
||||
downloads/
|
||||
eggs/
|
||||
.eggs/
|
||||
lib/
|
||||
lib64/
|
||||
parts/
|
||||
sdist/
|
||||
var/
|
||||
wheels/
|
||||
*.egg-info/
|
||||
.installed.cfg
|
||||
*.egg
|
||||
MANIFEST
|
||||
|
||||
# Installer logs
|
||||
pip-log.txt
|
||||
pip-delete-this-directory.txt
|
||||
|
||||
# Unit test / coverage reports
|
||||
htmlcov/
|
||||
.tox/
|
||||
.nox/
|
||||
.coverage
|
||||
.coverage.*
|
||||
.cache
|
||||
nosetests.xml
|
||||
coverage.xml
|
||||
*,cover
|
||||
*.log
|
||||
.pytest_cache/
|
||||
.hypothesis/
|
||||
|
||||
Reference in New Issue
Block a user