-
Notifications
You must be signed in to change notification settings - Fork 139
feat: Add Complete Docker and Docker Compose Support with Multi-Stage Builds #244
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. Weβll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
yogeshkumawat2027
wants to merge
2
commits into
AOSSIE-Org:main
Choose a base branch
from
yogeshkumawat2027:feature/docker-compose
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,83 @@ | ||
| # Docker Environment Variables Template | ||
|
|
||
| # Copy this file to .env and fill in your values | ||
| # cp .env.docker.example .env | ||
|
|
||
| # ============================================================ | ||
| # DATABASE CONFIGURATION | ||
| # ============================================================ | ||
|
|
||
| # PostgreSQL (if using local database instead of Supabase) | ||
| DB_USER=postgres | ||
| DB_PASSWORD=your_secure_password_here | ||
| DB_HOST=postgres | ||
| DB_PORT=5432 | ||
| DB_NAME=inpactai | ||
|
|
||
| # Or use Supabase connection (recommended) | ||
| # DB_USER=postgres | ||
| # DB_PASSWORD=your_supabase_password | ||
| # DB_HOST=db.xyzabcdefgh.supabase.co | ||
| # DB_PORT=5432 | ||
| # DB_NAME=postgres | ||
|
|
||
| # ============================================================ | ||
| # SUPABASE (Required) | ||
| # ============================================================ | ||
|
|
||
| SUPABASE_URL=https://your-project.supabase.co | ||
| SUPABASE_KEY=your_supabase_anon_key | ||
|
|
||
| # ============================================================ | ||
| # AI SERVICES | ||
| # ============================================================ | ||
|
|
||
| GEMINI_API_KEY=your_gemini_api_key | ||
| YOUTUBE_API_KEY=your_youtube_api_key | ||
|
|
||
| # ============================================================ | ||
| # REDIS | ||
| # ============================================================ | ||
|
|
||
| REDIS_PASSWORD=changeme_in_production | ||
| REDIS_PORT=6379 | ||
|
|
||
| # ============================================================ | ||
| # APPLICATION PORTS | ||
| # ============================================================ | ||
|
|
||
| BACKEND_PORT=8000 | ||
| FRONTEND_PORT=3000 | ||
| LANDING_PORT=3001 | ||
|
|
||
| # ============================================================ | ||
| # FRONTEND CONFIGURATION | ||
| # ============================================================ | ||
|
|
||
| # API URL for frontend (adjust for your deployment) | ||
| VITE_API_URL=http://localhost:8000 | ||
|
|
||
| # CORS Origins (comma-separated) | ||
| CORS_ORIGINS=http://localhost:3000,http://localhost:5173 | ||
|
|
||
| # ============================================================ | ||
| # ADVANCED DATABASE SETTINGS (Optional) | ||
| # ============================================================ | ||
|
|
||
| DB_POOL_SIZE=5 | ||
| DB_MAX_OVERFLOW=10 | ||
| DB_POOL_TIMEOUT=30 | ||
| DB_POOL_RECYCLE=3600 | ||
| DB_MAX_RETRIES=3 | ||
| DB_RETRY_DELAY=1.0 | ||
| DB_CONNECTION_TIMEOUT=10 | ||
| DB_PREFER_IPV4=true | ||
| DB_SSL_MODE=require | ||
| DB_USE_REST_FALLBACK=true | ||
|
|
||
| # ============================================================ | ||
| # PRODUCTION SETTINGS | ||
| # ============================================================ | ||
|
|
||
| # Set to false in production | ||
| DEBUG=false |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,82 @@ | ||
| # Python | ||
| __pycache__/ | ||
| *.py[cod] | ||
| *$py.class | ||
| *.so | ||
| .Python | ||
| build/ | ||
| develop-eggs/ | ||
| dist/ | ||
| downloads/ | ||
| eggs/ | ||
| .eggs/ | ||
| lib/ | ||
| lib64/ | ||
| parts/ | ||
| sdist/ | ||
| var/ | ||
| wheels/ | ||
| *.egg-info/ | ||
| .installed.cfg | ||
| *.egg | ||
| MANIFEST | ||
|
|
||
| # Virtual environments | ||
| venv/ | ||
| env/ | ||
| ENV/ | ||
| env.bak/ | ||
| venv.bak/ | ||
|
|
||
| # IDEs | ||
| .vscode/ | ||
| .idea/ | ||
| *.swp | ||
| *.swo | ||
| *~ | ||
| .DS_Store | ||
|
|
||
| # Environment files | ||
| .env | ||
| .env.local | ||
| .env.*.local | ||
|
|
||
| # Testing | ||
| .pytest_cache/ | ||
| .coverage | ||
| htmlcov/ | ||
| .tox/ | ||
|
|
||
| # Logs | ||
| *.log | ||
| logs/ | ||
|
|
||
| # Database | ||
| *.db | ||
| *.sqlite | ||
| *.sqlite3 | ||
|
|
||
| # Docker | ||
| Dockerfile | ||
| Dockerfile.* | ||
| .dockerignore | ||
| docker-compose*.yml | ||
|
|
||
| # Documentation | ||
| *.md | ||
| docs/ | ||
|
|
||
| # Git | ||
| .git/ | ||
| .gitignore | ||
| .gitattributes | ||
|
|
||
| # CI/CD | ||
| .github/ | ||
| .gitlab-ci.yml | ||
|
|
||
| # Misc | ||
| *.bak | ||
| *.tmp | ||
| *.temp | ||
| .cache/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,97 @@ | ||
| # Environment Configuration Template | ||
|
|
||
| # ============================================================ | ||
| # DATABASE CONFIGURATION (PostgreSQL/Supabase) | ||
| # ============================================================ | ||
|
|
||
| # Required: PostgreSQL Connection Credentials | ||
| user=your_database_user | ||
| password=your_database_password | ||
| host=your_database_host | ||
| port=5432 | ||
| dbname=your_database_name | ||
|
|
||
| # For Supabase users: | ||
| # 1. Go to: https://app.supabase.com/project/YOUR_PROJECT/settings/database | ||
| # 2. Copy connection details from the "Connection string" section | ||
| # 3. Extract the credentials and paste them above | ||
|
|
||
| # Example for Supabase: | ||
| # user=postgres | ||
| # password=your_project_password | ||
| # host=db.xyzabcdefgh.supabase.co | ||
| # port=5432 | ||
| # dbname=postgres | ||
|
|
||
| # ============================================================ | ||
| # SUPABASE REST API (Fallback & Additional Features) | ||
| # ============================================================ | ||
|
|
||
| # Required for REST API fallback when PostgreSQL fails | ||
| SUPABASE_URL=https://your-project.supabase.co | ||
| SUPABASE_KEY=your_supabase_anon_key | ||
|
|
||
| # Get these from: | ||
| # https://app.supabase.com/project/YOUR_PROJECT/settings/api | ||
|
|
||
| # ============================================================ | ||
| # AI SERVICES | ||
| # ============================================================ | ||
|
|
||
| # Google Gemini API (for trending niches) | ||
| GEMINI_API_KEY=your_gemini_api_key | ||
| # Get from: https://makersuite.google.com/app/apikey | ||
|
|
||
| # YouTube Data API (for channel info) | ||
| YOUTUBE_API_KEY=your_youtube_api_key | ||
| # Get from: https://console.cloud.google.com/apis/credentials | ||
|
|
||
| # ============================================================ | ||
| # ADVANCED DATABASE SETTINGS (Optional) | ||
| # ============================================================ | ||
|
|
||
| # Connection Pool Configuration | ||
| DB_POOL_SIZE=5 # Number of connections in the pool | ||
| DB_MAX_OVERFLOW=10 # Additional connections allowed beyond pool_size | ||
| DB_POOL_TIMEOUT=30 # Seconds to wait for a connection from the pool | ||
| DB_POOL_RECYCLE=3600 # Recycle connections after N seconds (1 hour) | ||
|
|
||
| # Connection Retry Settings | ||
| DB_MAX_RETRIES=3 # Number of connection retry attempts | ||
| DB_RETRY_DELAY=1.0 # Initial delay between retries (exponential backoff) | ||
| DB_CONNECTION_TIMEOUT=10 # Seconds to wait for connection establishment | ||
|
|
||
| # IPv6/Network Settings | ||
| DB_PREFER_IPV4=true # Prefer IPv4 connections (helps with IPv6 issues) | ||
| DB_SSL_MODE=require # SSL mode: disable, allow, prefer, require, verify-ca, verify-full | ||
|
|
||
| # Fallback Configuration | ||
| DB_USE_REST_FALLBACK=true # Use Supabase REST API when PostgreSQL fails | ||
|
|
||
| # ============================================================ | ||
| # APPLICATION SETTINGS (Optional) | ||
| # ============================================================ | ||
|
|
||
| # Debug mode (shows detailed errors) | ||
| DEBUG=false | ||
|
|
||
| # CORS Origins (comma-separated) | ||
| CORS_ORIGINS=http://localhost:5173,http://localhost:3000 | ||
|
|
||
| # ============================================================ | ||
| # TROUBLESHOOTING | ||
| # ============================================================ | ||
|
|
||
| # If you experience connection issues: | ||
| # 1. IPv6 Issues: Set DB_PREFER_IPV4=true and use Supabase Connection Pooler | ||
| # 2. Timeout Issues: Increase DB_CONNECTION_TIMEOUT and DB_POOL_TIMEOUT | ||
| # 3. SSL Issues: Try DB_SSL_MODE=disable for local development | ||
| # 4. General Issues: Enable DEBUG=true for detailed error messages | ||
|
|
||
| # For Supabase Connection Pooler (IPv4 compatible): | ||
| # 1. Enable in Supabase Dashboard β Database β Connection Pooler | ||
| # 2. Update your host: | ||
| # host=aws-0-us-east-1.pooler.supabase.com | ||
| # port=6543 | ||
|
|
||
| # See DATABASE_SETUP.md for detailed troubleshooting guide | ||
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Inconsistent naming convention for database credentials.
The database credential keys (
user,password,host,port,dbname) use lowercase, while all other environment variables follow UPPERCASE_WITH_UNDERSCORES convention. This inconsistency can lead to confusion and errors.Consider standardizing to uppercase for consistency:
Important: This change requires updating
Backend/app/config.py(lines 17-21) to use the new variable names.π§° Tools
πͺ dotenv-linter (4.0.0)
[warning] 8-8: [LowercaseKey] The user key should be in uppercase
(LowercaseKey)
[warning] 9-9: [LowercaseKey] The password key should be in uppercase
(LowercaseKey)
[warning] 9-9: [UnorderedKey] The password key should go before the user key
(UnorderedKey)
[warning] 10-10: [LowercaseKey] The host key should be in uppercase
(LowercaseKey)
[warning] 10-10: [UnorderedKey] The host key should go before the password key
(UnorderedKey)
[warning] 11-11: [LowercaseKey] The port key should be in uppercase
(LowercaseKey)
[warning] 11-11: [UnorderedKey] The port key should go before the user key
(UnorderedKey)
[warning] 12-12: [LowercaseKey] The dbname key should be in uppercase
(LowercaseKey)
[warning] 12-12: [UnorderedKey] The dbname key should go before the host key
(UnorderedKey)
π€ Prompt for AI Agents