devops: added docker files for conteiner web-robot-control-app

This commit is contained in:
Arduinum628
2026-01-27 13:31:18 +03:00
parent d1adcf1bd9
commit d496f0fa6b
3 changed files with 106 additions and 0 deletions

78
.dockerignore Normal file
View File

@@ -0,0 +1,78 @@
# Git
.git
.gitignore
.gitattributes
# Python
__pycache__
*.py[cod]
*$py.class
*.so
.Python
build/
develop-eggs/
dist/
downloads/
eggs/
.eggs/
lib/
lib64/
parts/
sdist/
var/
wheels/
pip-wheel-metadata/
share/python-wheels/
*.egg-info/
.installed.cfg
*.egg
MANIFEST
.pytest_cache/
.coverage
.coverage.*
htmlcov/
# Virtual Environments
venv/
ENV/
env/
.venv
.env
.env.local
.env.*.local
# IDE
.vscode/
.idea/
*.swp
*.swo
*~
.DS_Store
.ropeproject
# Project specific
.cache/
.ruff_cache/
*.db
.pytest_cache/
# Docker
.docker
.dockerignore
Dockerfile
# Build artifacts
.flatpak-builder/
build-dir/
# Node (если используется)
node_modules/
npm-debug.log
yarn-error.log
# OS
.DS_Store
Thumbs.db
# app
tests/

13
Dockerfile Normal file
View File

@@ -0,0 +1,13 @@
FROM python:3.12.0-slim
WORKDIR /app
ENV PYTHONUNBUFFERED=1 \
PYTHONDONTWRITEBYTECODE=1
COPY . /app
RUN pip install poetry
RUN poetry config virtualenvs.create false && \
poetry install --no-interaction --no-ansi

15
docker-compose.yml Normal file
View File

@@ -0,0 +1,15 @@
services:
app:
build: .
image: arduinum628/web-robot-control-app:latest
container_name: web_robot_control
command: poetry run start_app
env_file:
- .env
ports:
- "${PORT_APP}:${PORT_APP}"
volumes:
- app:/app
volumes:
app: