Add configuration template files (.env.example, .dockerignore)
Added essential configuration templates that were missing from the repository due to overly restrictive .gitignore patterns. Changes to .gitignore: - Added negation patterns for .env.example files - Added negation patterns for .dockerignore files - These are safe template files with placeholder values Files added: - .env.example (root): Main environment configuration template - reports-app/backend/.env.example: Backend configuration template - reports-app/frontend/.env.example: Frontend configuration template - reports-app/telegram-bot/.env.example: Telegram bot config template - reports-app/telegram-bot/.dockerignore: Docker build exclusions These template files help developers quickly set up their local development environment by copying and customizing them. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
112
.env.example
Normal file
112
.env.example
Normal file
@@ -0,0 +1,112 @@
|
|||||||
|
# ROA2WEB Environment Variables Configuration
|
||||||
|
# Copy this file to .env and update with your actual values
|
||||||
|
|
||||||
|
# =============================================================================
|
||||||
|
# ORACLE DATABASE CONFIGURATION
|
||||||
|
# =============================================================================
|
||||||
|
|
||||||
|
# Oracle database connection
|
||||||
|
ORACLE_USER=your_oracle_username
|
||||||
|
ORACLE_PASSWORD=your_oracle_password
|
||||||
|
ORACLE_DSN=your_oracle_connection_string
|
||||||
|
|
||||||
|
# Oracle Instant Client Path (local development only)
|
||||||
|
INSTANTCLIENTPATH=/path/to/oracle/instantclient
|
||||||
|
|
||||||
|
# Database Connection Pool Settings
|
||||||
|
DB_MIN_CONNECTIONS=2
|
||||||
|
DB_MAX_CONNECTIONS=10
|
||||||
|
DB_CONNECTION_INCREMENT=1
|
||||||
|
|
||||||
|
# =============================================================================
|
||||||
|
# JWT AUTHENTICATION CONFIGURATION
|
||||||
|
# =============================================================================
|
||||||
|
|
||||||
|
# JWT Secret Key - CHANGE THIS IN PRODUCTION!
|
||||||
|
# Generate a secure key: python -c "import secrets; print(secrets.token_urlsafe(32))"
|
||||||
|
JWT_SECRET_KEY=your-super-secret-jwt-key-change-in-production
|
||||||
|
|
||||||
|
# JWT Algorithm
|
||||||
|
JWT_ALGORITHM=HS256
|
||||||
|
|
||||||
|
# Token Expiration Settings
|
||||||
|
ACCESS_TOKEN_EXPIRE_MINUTES=30
|
||||||
|
REFRESH_TOKEN_EXPIRE_DAYS=7
|
||||||
|
|
||||||
|
# =============================================================================
|
||||||
|
# AUTHENTICATION SETTINGS
|
||||||
|
# =============================================================================
|
||||||
|
|
||||||
|
# User data cache TTL (minutes)
|
||||||
|
AUTH_CACHE_TTL_MINUTES=15
|
||||||
|
|
||||||
|
# Rate Limiting Settings
|
||||||
|
RATE_LIMIT_MAX_REQUESTS=5
|
||||||
|
RATE_LIMIT_TIME_WINDOW=300
|
||||||
|
|
||||||
|
# =============================================================================
|
||||||
|
# LOGGING CONFIGURATION
|
||||||
|
# =============================================================================
|
||||||
|
|
||||||
|
# Log Level (DEBUG, INFO, WARNING, ERROR, CRITICAL)
|
||||||
|
LOG_LEVEL=INFO
|
||||||
|
|
||||||
|
# =============================================================================
|
||||||
|
# FASTAPI APPLICATION SETTINGS
|
||||||
|
# =============================================================================
|
||||||
|
|
||||||
|
# FastAPI Development Settings
|
||||||
|
FASTAPI_HOST=127.0.0.1
|
||||||
|
FASTAPI_PORT=8000
|
||||||
|
FASTAPI_RELOAD=true
|
||||||
|
|
||||||
|
# CORS Settings
|
||||||
|
CORS_ORIGINS=["http://localhost:3000", "http://localhost:5173", "http://localhost:8080"]
|
||||||
|
|
||||||
|
# =============================================================================
|
||||||
|
# VUE.JS FRONTEND SETTINGS
|
||||||
|
# =============================================================================
|
||||||
|
|
||||||
|
# API Base URL for Vue.js frontend
|
||||||
|
VUE_APP_API_URL=http://localhost:8000
|
||||||
|
|
||||||
|
# Vue.js Development Server
|
||||||
|
VUE_DEV_PORT=3000
|
||||||
|
|
||||||
|
# =============================================================================
|
||||||
|
# DOCKER CONFIGURATION
|
||||||
|
# =============================================================================
|
||||||
|
|
||||||
|
# Docker Compose Settings
|
||||||
|
COMPOSE_PROJECT_NAME=roa2web
|
||||||
|
|
||||||
|
# Nginx Gateway Port
|
||||||
|
NGINX_PORT=8080
|
||||||
|
NGINX_SSL_PORT=8443
|
||||||
|
|
||||||
|
# =============================================================================
|
||||||
|
# PRODUCTION DEPLOYMENT
|
||||||
|
# =============================================================================
|
||||||
|
|
||||||
|
# Environment (development, staging, production)
|
||||||
|
ENVIRONMENT=development
|
||||||
|
|
||||||
|
# Security Settings
|
||||||
|
SECURE_SSL_REDIRECT=false
|
||||||
|
SESSION_COOKIE_SECURE=false
|
||||||
|
CSRF_COOKIE_SECURE=false
|
||||||
|
|
||||||
|
# Database Connection Timeout
|
||||||
|
DB_CONNECTION_TIMEOUT=30
|
||||||
|
|
||||||
|
# =============================================================================
|
||||||
|
# MONITORING & OBSERVABILITY
|
||||||
|
# =============================================================================
|
||||||
|
|
||||||
|
# Metrics and Monitoring
|
||||||
|
ENABLE_METRICS=false
|
||||||
|
METRICS_PORT=9090
|
||||||
|
|
||||||
|
# Health Check Settings
|
||||||
|
HEALTH_CHECK_TIMEOUT=10
|
||||||
|
HEALTH_CHECK_INTERVAL=30
|
||||||
7
.gitignore
vendored
7
.gitignore
vendored
@@ -247,7 +247,6 @@ quick_test.*
|
|||||||
.dmypy.json
|
.dmypy.json
|
||||||
.docker/
|
.docker/
|
||||||
.dockerignore
|
.dockerignore
|
||||||
.dockerignore
|
|
||||||
.eggs/
|
.eggs/
|
||||||
.eggs/
|
.eggs/
|
||||||
.env
|
.env
|
||||||
@@ -258,6 +257,12 @@ quick_test.*
|
|||||||
.env.production
|
.env.production
|
||||||
.env.production
|
.env.production
|
||||||
.env.test
|
.env.test
|
||||||
|
# Allow .env.example files (configuration templates)
|
||||||
|
!.env.example
|
||||||
|
!**/.env.example
|
||||||
|
# Allow .dockerignore files (Docker build configuration)
|
||||||
|
!.dockerignore
|
||||||
|
!**/.dockerignore
|
||||||
.gcp/
|
.gcp/
|
||||||
.hypothesis/
|
.hypothesis/
|
||||||
.hypothesis/
|
.hypothesis/
|
||||||
|
|||||||
39
reports-app/backend/.env.example
Normal file
39
reports-app/backend/.env.example
Normal file
@@ -0,0 +1,39 @@
|
|||||||
|
# Oracle Database Configuration (prin SSH tunnel)
|
||||||
|
# IMPORTANT: Conectare la schema CONTAFIN_ORACLE pentru authentication
|
||||||
|
# Schema CONTAFIN_ORACLE conține utilizatorii și pack_drepturi.verificautilizator
|
||||||
|
# Fiecare firmă este o schema separată în Oracle
|
||||||
|
ORACLE_USER=CONTAFIN_ORACLE
|
||||||
|
ORACLE_PASSWORD=SET_IN_PRODUCTION_ENV
|
||||||
|
ORACLE_HOST=localhost
|
||||||
|
ORACLE_PORT=1526
|
||||||
|
ORACLE_SID=ROA
|
||||||
|
|
||||||
|
# Authentication Flow Information:
|
||||||
|
# 1. Conectare la CONTAFIN_ORACLE schema
|
||||||
|
# 2. Verificare user/pass prin pack_drepturi.verificautilizator(username, password)
|
||||||
|
# 3. Citire drepturi/firme din vdef_util_grup WHERE id_util = user_id
|
||||||
|
# 4. User selectează firma/schema pentru acces la date
|
||||||
|
|
||||||
|
# Test User Credentials (pentru dezvoltare):
|
||||||
|
# 🔐 SECURITY: Nu pune credențiale reale în acest fișier!
|
||||||
|
# Username: "SET_IN_PRODUCTION"
|
||||||
|
# Password: "SET_IN_PRODUCTION"
|
||||||
|
# Are acces la 66+ firme/scheme Oracle
|
||||||
|
|
||||||
|
# SSH Tunnel Setup Required:
|
||||||
|
# Rulează: ./ssh_tunnel.sh start
|
||||||
|
# Verifică: ./ssh_tunnel.sh status
|
||||||
|
|
||||||
|
# JWT Configuration
|
||||||
|
# 🔐 SECURITY: Generate a strong secret key in production!
|
||||||
|
JWT_SECRET_KEY=GENERATE_STRONG_SECRET_IN_PRODUCTION
|
||||||
|
ACCESS_TOKEN_EXPIRE_MINUTES=30
|
||||||
|
REFRESH_TOKEN_EXPIRE_DAYS=7
|
||||||
|
|
||||||
|
# Application Configuration
|
||||||
|
API_HOST=0.0.0.0
|
||||||
|
API_PORT=8000
|
||||||
|
DEBUG=True
|
||||||
|
|
||||||
|
# CORS Configuration
|
||||||
|
FRONTEND_URLS=http://localhost:3000,http://localhost:5173
|
||||||
14
reports-app/frontend/.env.example
Normal file
14
reports-app/frontend/.env.example
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
# API Configuration
|
||||||
|
VITE_API_BASE_URL=http://localhost:8000
|
||||||
|
VITE_API_TIMEOUT=10000
|
||||||
|
|
||||||
|
# Application Configuration
|
||||||
|
VITE_APP_TITLE=ROA Reports
|
||||||
|
VITE_APP_VERSION=1.0.0
|
||||||
|
|
||||||
|
# Telegram Bot Configuration
|
||||||
|
VITE_TELEGRAM_BOT_USERNAME=roa2web_bot
|
||||||
|
|
||||||
|
# Development Configuration
|
||||||
|
VITE_DEBUG=true
|
||||||
|
VITE_LOG_LEVEL=debug
|
||||||
66
reports-app/telegram-bot/.dockerignore
Normal file
66
reports-app/telegram-bot/.dockerignore
Normal file
@@ -0,0 +1,66 @@
|
|||||||
|
# Python
|
||||||
|
__pycache__/
|
||||||
|
*.py[cod]
|
||||||
|
*$py.class
|
||||||
|
*.so
|
||||||
|
.Python
|
||||||
|
*.egg-info/
|
||||||
|
dist/
|
||||||
|
build/
|
||||||
|
*.egg
|
||||||
|
|
||||||
|
# Virtual environments
|
||||||
|
venv/
|
||||||
|
env/
|
||||||
|
ENV/
|
||||||
|
.venv
|
||||||
|
|
||||||
|
# Environment files
|
||||||
|
.env
|
||||||
|
.env.local
|
||||||
|
.env.*.local
|
||||||
|
|
||||||
|
# SQLite database files
|
||||||
|
*.db
|
||||||
|
*.db-shm
|
||||||
|
*.db-wal
|
||||||
|
data/*.db
|
||||||
|
|
||||||
|
# IDE
|
||||||
|
.vscode/
|
||||||
|
.idea/
|
||||||
|
*.swp
|
||||||
|
*.swo
|
||||||
|
*~
|
||||||
|
|
||||||
|
# Testing
|
||||||
|
.pytest_cache/
|
||||||
|
.coverage
|
||||||
|
htmlcov/
|
||||||
|
.tox/
|
||||||
|
|
||||||
|
# Git
|
||||||
|
.git/
|
||||||
|
.gitignore
|
||||||
|
.gitattributes
|
||||||
|
|
||||||
|
# Documentation
|
||||||
|
*.md
|
||||||
|
docs/
|
||||||
|
|
||||||
|
# Docker
|
||||||
|
Dockerfile
|
||||||
|
.dockerignore
|
||||||
|
docker-compose*.yml
|
||||||
|
|
||||||
|
# CI/CD
|
||||||
|
.github/
|
||||||
|
.gitlab-ci.yml
|
||||||
|
|
||||||
|
# OS
|
||||||
|
.DS_Store
|
||||||
|
Thumbs.db
|
||||||
|
|
||||||
|
# Logs
|
||||||
|
*.log
|
||||||
|
logs/
|
||||||
76
reports-app/telegram-bot/.env.example
Normal file
76
reports-app/telegram-bot/.env.example
Normal file
@@ -0,0 +1,76 @@
|
|||||||
|
# ============================================================================
|
||||||
|
# ROA2WEB Telegram Bot - Environment Configuration
|
||||||
|
# ============================================================================
|
||||||
|
# Copy this file to .env and fill in your actual values
|
||||||
|
# IMPORTANT: Never commit .env file to git!
|
||||||
|
|
||||||
|
# ============================================================================
|
||||||
|
# REQUIRED CONFIGURATION
|
||||||
|
# ============================================================================
|
||||||
|
|
||||||
|
# Telegram Bot Configuration
|
||||||
|
# Obtain from @BotFather on Telegram
|
||||||
|
TELEGRAM_BOT_TOKEN=your_bot_token_here
|
||||||
|
|
||||||
|
# Claude Authentication Configuration
|
||||||
|
# ============================================================================
|
||||||
|
# You have TWO options for Claude authentication:
|
||||||
|
#
|
||||||
|
# OPTION 1: API Key (pay per token - requires API credits)
|
||||||
|
# - Get API key from: https://console.anthropic.com/
|
||||||
|
# - Set CLAUDE_API_KEY below
|
||||||
|
# - You will be charged per API usage (separate from Claude subscription)
|
||||||
|
#
|
||||||
|
# OPTION 2: Claude Pro/Max Subscription (RECOMMENDED if you have subscription)
|
||||||
|
# - If you have Claude Pro or Claude Max subscription
|
||||||
|
# - Run: claude-code login (one-time setup)
|
||||||
|
# - Leave CLAUDE_API_KEY empty or commented out
|
||||||
|
# - You won't pay extra API credits (uses your existing subscription)
|
||||||
|
#
|
||||||
|
# For development/local usage: Use Option 2 if you have subscription
|
||||||
|
# For Docker/production: Use Option 1 (API key is simpler in containers)
|
||||||
|
# ============================================================================
|
||||||
|
|
||||||
|
# OPTION 1: Set this if using API key
|
||||||
|
CLAUDE_API_KEY=
|
||||||
|
|
||||||
|
# OPTION 2: Leave empty and run "claude-code login" before starting bot
|
||||||
|
|
||||||
|
# Backend API URL
|
||||||
|
# Development: http://localhost:8001
|
||||||
|
# Docker: http://roa-backend:8000
|
||||||
|
BACKEND_URL=http://roa-backend:8000
|
||||||
|
|
||||||
|
# ============================================================================
|
||||||
|
# DATABASE CONFIGURATION
|
||||||
|
# ============================================================================
|
||||||
|
|
||||||
|
# SQLite Database Path (STANDALONE)
|
||||||
|
# This is where user data, auth codes, and sessions are stored
|
||||||
|
# Development: ./data/telegram_bot.db
|
||||||
|
# Docker: /app/data/telegram_bot.db
|
||||||
|
SQLITE_DB_PATH=/app/data/telegram_bot.db
|
||||||
|
|
||||||
|
# ============================================================================
|
||||||
|
# NETWORKING CONFIGURATION
|
||||||
|
# ============================================================================
|
||||||
|
|
||||||
|
# Internal API Port (for backend to call telegram-bot)
|
||||||
|
# This port is used by the backend to save auth codes
|
||||||
|
INTERNAL_API_PORT=8002
|
||||||
|
|
||||||
|
# ============================================================================
|
||||||
|
# OPTIONAL CONFIGURATION
|
||||||
|
# ============================================================================
|
||||||
|
|
||||||
|
# Logging Level
|
||||||
|
# Options: DEBUG, INFO, WARNING, ERROR, CRITICAL
|
||||||
|
LOG_LEVEL=INFO
|
||||||
|
|
||||||
|
# Sentry DSN for error monitoring (optional)
|
||||||
|
# Get from: https://sentry.io/
|
||||||
|
SENTRY_DSN=
|
||||||
|
|
||||||
|
# Environment
|
||||||
|
# Options: development, production
|
||||||
|
ENVIRONMENT=production
|
||||||
Reference in New Issue
Block a user