updated directories

This commit is contained in:
Berkay 2025-05-10 13:20:31 +03:00
parent 99fa410a83
commit 7018853a48
12 changed files with 367 additions and 0 deletions

162
.gitignore vendored Normal file
View File

@ -0,0 +1,162 @@
# ---> Python
# Byte-compiled / optimized / DLL files
__pycache__/
*.py[cod]
*$py.class
# C extensions
*.so
# Distribution / packaging
.Python
build/
develop-eggs/
dist/
downloads/
eggs/
.eggs/
lib/
lib64/
parts/
sdist/
var/
wheels/
share/python-wheels/
*.egg-info/
.installed.cfg
*.egg
MANIFEST
# PyInstaller
# Usually these files are written by a python script from a template
# before PyInstaller builds the exe, so as to inject date/other infos into it.
*.manifest
*.spec
# 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
*.py,cover
.hypothesis/
.pytest_cache/
cover/
# Translations
*.mo
*.pot
# Django stuff:
*.log
local_settings.py
db.sqlite3
db.sqlite3-journal
# Flask stuff:
instance/
.webassets-cache
# Scrapy stuff:
.scrapy
# Sphinx documentation
docs/_build/
# PyBuilder
.pybuilder/
target/
# Jupyter Notebook
.ipynb_checkpoints
# IPython
profile_default/
ipython_config.py
# pyenv
# For a library or package, you might want to ignore these files since the code is
# intended to run in multiple environments; otherwise, check them in:
# .python-version
# pipenv
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
# However, in case of collaboration, if having platform-specific dependencies or dependencies
# having no cross-platform support, pipenv may install dependencies that don't work, or not
# install all needed dependencies.
#Pipfile.lock
# poetry
# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
# This is especially recommended for binary packages to ensure reproducibility, and is more
# commonly ignored for libraries.
# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
#poetry.lock
# pdm
# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
#pdm.lock
# pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it
# in version control.
# https://pdm.fming.dev/#use-with-ide
.pdm.toml
# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
__pypackages__/
# Celery stuff
celerybeat-schedule
celerybeat.pid
# SageMath parsed files
*.sage.py
# Environments
.env
.venv
env/
venv/
ENV/
env.bak/
venv.bak/
# Spyder project settings
.spyderproject
.spyproject
# Rope project settings
.ropeproject
# mkdocs documentation
/site
# mypy
.mypy_cache/
.dmypy.json
dmypy.json
# Pyre type checker
.pyre/
# pytype static type analyzer
.pytype/
# Cython debug symbols
cython_debug/
# PyCharm
# JetBrains specific template is maintained in a separate JetBrains.gitignore that can
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
# and can be added to the global gitignore or merged into this file. For a more nuclear
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
.idea/

41
api_env.env Normal file
View File

@ -0,0 +1,41 @@
MONGO_ENGINE=mongodb
MONGO_DB=appdb
MONGO_HOST=10.10.2.13
MONGO_PORT=27017
MONGO_USER=appuser
MONGO_AUTH_DB=appdb
MONGO_PASSWORD=apppassword
POSTGRES_USER=postgres
POSTGRES_PASSWORD=password
POSTGRES_DB=postgres
POSTGRES_HOST=10.10.2.14
POSTGRES_PORT=5432
POSTGRES_ENGINE=postgresql+psycopg2
POSTGRES_POOL_PRE_PING=True
POSTGRES_POOL_SIZE=20
POSTGRES_MAX_OVERFLOW=10
POSTGRES_POOL_RECYCLE=600
POSTGRES_POOL_TIMEOUT=30
POSTGRES_ECHO=True
REDIS_HOST=10.10.2.15
REDIS_PASSWORD=your_strong_password_here
REDIS_PORT=6379
REDIS_DB=0
API_ACCESS_EMAIL_EXT=evyos.com.tr
API_ALGORITHM=HS256
API_ACCESS_TOKEN_LENGTH=90
API_REFRESHER_TOKEN_LENGTH=144
API_EMAIL_HOST=10.10.2.36
API_DATETIME_FORMAT=YYYY-MM-DD HH:mm:ss Z
API_FORGOT_LINK=https://www.evyos.com.tr/password/create?tokenUrl=
API_VERSION=0.1.001
API_ACCESS_TOKEN_TAG=eys-acs-tkn
EMAIL_HOST=10.10.2.34
EMAIL_USERNAME=karatay@mehmetkaratay.com.tr
EMAIL_PASSWORD=system
EMAIL_PORT=587
EMAIL_SEND=0

View File

@ -0,0 +1,129 @@
services:
email_service:
container_name: email_service
build:
context: .
dockerfile: BankServices/EmailService/Dockerfile
networks:
- bank-services-network
environment:
- MAILBOX=bilgilendirme@ileti.isbank.com.tr
- MAIN_MAIL=karatay.berkay@gmail.com
- INFO_MAIL=mehmet.karatay@hotmail.com
- EMAIL_HOST=10.10.2.34
- EMAIL_USERNAME=isbank@mehmetkaratay.com.tr
- EMAIL_PASSWORD=system
- EMAIL_PORT=993
- EMAIL_SEND_PORT=587
- EMAIL_SLEEP=60
- AUTHORIZE_IBAN=4245-0093333
- REDIS_HOST=10.10.2.15
- REDIS_PORT=6379
- REDIS_PASSWORD=your_strong_password_here
restart: unless-stopped
volumes:
- tempory-email-service:/tmp
logging:
driver: "json-file"
options:
max-size: "10m"
max-file: "3"
parser_service:
container_name: parser_service
build:
context: .
dockerfile: BankServices/ParserService/Dockerfile
networks:
- bank-services-network
environment:
- REDIS_HOST=10.10.2.15
- REDIS_PORT=6379
- REDIS_PASSWORD=your_strong_password_here
restart: unless-stopped
logging:
driver: "json-file"
options:
max-size: "10m"
max-file: "3"
writer_service:
container_name: writer_service
build:
context: .
dockerfile: BankServices/WriterService/Dockerfile
networks:
- bank-services-network
environment:
- REDIS_HOST=10.10.2.15
- REDIS_PORT=6379
- REDIS_PASSWORD=your_strong_password_here
- DB_HOST=10.10.2.14
- DB_PORT=5432
- DB_USER=postgres
- DB_PASSWORD=password
- DB_NAME=postgres
restart: unless-stopped
logging:
driver: "json-file"
options:
max-size: "10m"
max-file: "3"
routine_email_service:
container_name: routine_email_service
build:
context: .
dockerfile: BankServices/RoutineEmailService/Dockerfile
entrypoint: ["/entrypoint.sh"]
networks:
- bank-services-network
environment:
- EMAIL_HOST=10.10.2.34
- EMAIL_USERNAME=karatay@mehmetkaratay.com.tr
- EMAIL_PASSWORD=system
- EMAIL_PORT=587
- EMAIL_SEND=1
- DB_HOST=10.10.2.14
- DB_PORT=5432
- DB_USER=postgres
- DB_PASSWORD=password
- DB_NAME=postgres
restart: unless-stopped
logging:
driver: "json-file"
options:
max-size: "10m"
max-file: "3"
sender_service:
container_name: sender_service
build:
context: .
dockerfile: BankServices/SenderService/Dockerfile
networks:
- bank-services-network
environment:
- EMAIL_HOST=10.10.2.34
- EMAIL_USERNAME=karatay@mehmetkaratay.com.tr
- EMAIL_PASSWORD=system
- EMAIL_PORT=587
- EMAIL_SEND=1
- DB_HOST=10.10.2.14
- DB_PORT=5432
- DB_USER=postgres
- DB_PASSWORD=password
- DB_NAME=postgres
restart: unless-stopped
logging:
driver: "json-file"
options:
max-size: "10m"
max-file: "3"
networks:
bank-services-network:
driver: bridge
volumes:
tempory-email-service:

View File

@ -0,0 +1,9 @@
services:
test_server:
container_name: test_server
build:
context: .
dockerfile: ApiServices/Dockerfile
env_file:
- api_env.env

26
run_bank_services.sh Executable file
View File

@ -0,0 +1,26 @@
#!/bin/bash
# Simple script to restart bank services
# Created: 2025-04-20
# Set the working directory to the script's location
cd "$(dirname "$0")"
echo "Working directory: $(pwd)"
# Configuration
COMPOSE_FILE="bank-services-docker-compose.yml"
# Check if the compose file exists
if [ ! -f "$COMPOSE_FILE" ]; then
echo "ERROR: Compose file $COMPOSE_FILE not found in $(pwd)"
exit 1
fi
echo "$(date '+%Y-%m-%d %H:%M:%S') Stopping any running bank services..."
docker compose -f "$COMPOSE_FILE" down
echo "$(date '+%Y-%m-%d %H:%M:%S') Rebuilding and starting bank services..."
docker compose -f "$COMPOSE_FILE" up --build -d
echo "$(date '+%Y-%m-%d %H:%M:%S') Bank services restart completed"
exit 0

0
run_web_services.sh Normal file
View File

View File