|
| 1 | +# =================================== |
| 2 | +# SupplyChain-Auth Environment Template |
| 3 | +# Copy to `.env` and replace placeholder values locally |
| 4 | +# =================================== |
| 5 | + |
| 6 | +# Application Environment |
| 7 | +NODE_ENV=development |
| 8 | +REACT_APP_ENV=development |
| 9 | + |
| 10 | +# =================================== |
| 11 | +# API Configuration |
| 12 | +# =================================== |
| 13 | +REACT_APP_API_BASE_URL=http://localhost:8080 |
| 14 | +REACT_APP_API_PRODUCTS_URL=http://localhost:8080/api/products |
| 15 | +REACT_APP_API_VERIFICATION_URL=http://localhost:8080/api/verify |
| 16 | +REACT_APP_API_EVENTS_URL=http://localhost:8080/api/events |
| 17 | + |
| 18 | +# Backend Service URLs |
| 19 | +PRODUCT_SERVICE_URL=http://localhost:8081 |
| 20 | +VERIFICATION_SERVICE_URL=http://localhost:8082 |
| 21 | +EVENT_SERVICE_URL=http://localhost:8083 |
| 22 | + |
| 23 | +# =================================== |
| 24 | +# Database Configuration |
| 25 | +# =================================== |
| 26 | +MONGODB_URI=mongodb://localhost:27017/supplychain_auth |
| 27 | +MONGODB_DATABASE=supplychain_auth |
| 28 | +MONGODB_USERNAME=<mongo_username> |
| 29 | +MONGODB_PASSWORD=<mongo_password> |
| 30 | + |
| 31 | +REDIS_URL=redis://localhost:6379 |
| 32 | +REDIS_PASSWORD=<redis_password> |
| 33 | + |
| 34 | +POSTGRES_URL=postgresql://localhost:5432/supplychain_auth |
| 35 | +POSTGRES_USERNAME=<postgres_username> |
| 36 | +POSTGRES_PASSWORD=<postgres_password> |
| 37 | + |
| 38 | +# =================================== |
| 39 | +# Blockchain Configuration (Free Testnet) |
| 40 | +# =================================== |
| 41 | +BLOCKCHAIN_NETWORK=sepolia |
| 42 | +ETHEREUM_RPC_URL=https://sepolia.infura.io/v3/<infura_project_id> |
| 43 | +PRIVATE_KEY=<private_key_for_testnet> |
| 44 | +CONTRACT_ADDRESS=<deployed_contract_address> |
| 45 | + |
| 46 | +# =================================== |
| 47 | +# Security Configuration |
| 48 | +# =================================== |
| 49 | +JWT_SECRET=<generate_strong_jwt_secret> |
| 50 | +JWT_EXPIRES_IN=24h |
| 51 | +JWT_REFRESH_EXPIRES_IN=7d |
| 52 | +ENCRYPTION_KEY=<32_byte_hex_key> |
| 53 | + |
| 54 | +# =================================== |
| 55 | +# External Services (Free Tiers) |
| 56 | +# =================================== |
| 57 | +EMAIL_SERVICE_API_KEY=<mailgun_api_key> |
| 58 | +EMAIL_FROM=<noreply@example.com> |
| 59 | + |
| 60 | +STORAGE_TYPE=local |
| 61 | +STORAGE_PATH=./uploads |
| 62 | + |
| 63 | +# =================================== |
| 64 | +# Monitoring & Logging |
| 65 | +# =================================== |
| 66 | +LOG_LEVEL=info |
| 67 | +METRICS_ENABLED=true |
| 68 | +METRICS_PORT=9090 |
| 69 | + |
| 70 | +# =================================== |
| 71 | +# Application Settings |
| 72 | +# =================================== |
| 73 | +PORT=8080 |
| 74 | +HOST=localhost |
| 75 | +CORS_ORIGINS=http://localhost:3000,https://your-app.vercel.app |
| 76 | +RATE_LIMIT_WINDOW_MS=900000 |
| 77 | +RATE_LIMIT_MAX_REQUESTS=100 |
| 78 | + |
| 79 | +# =================================== |
| 80 | +# Development Settings |
| 81 | +# =================================== |
| 82 | +DEBUG_MODE=true |
| 83 | +ENABLE_SWAGGER=true |
| 84 | +CHOKIDAR_USEPOLLING=true |
| 85 | + |
| 86 | +# =================================== |
| 87 | +# Production Overrides (set via deployment env) |
| 88 | +# =================================== |
| 89 | +# REACT_APP_API_BASE_URL=https://your-backend.example.com |
| 90 | +# MONGODB_URI=<production_mongodb_connection> |
| 91 | +# REDIS_URL=<production_redis_connection> |
| 92 | +# JWT_SECRET=<production_jwt_secret> |
0 commit comments