Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
65 changes: 65 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
# Environment Configuration
ENVIRONMENT=development
LOG_LEVEL=INFO

# LLM API Keys
GEMINI_API_KEY=your-gemini-api-key-here
OPENAI_API_KEY=your-openai-api-key-here
ANTHROPIC_API_KEY=your-anthropic-api-key-here
MISTRAL_API_KEY=your-mistral-api-key-here

# Google Cloud
GOOGLE_PROJECT_ID=your-gcp-project-id
GOOGLE_REGION=us-central1
GOOGLE_APPLICATION_CREDENTIALS=/path/to/service-account.json

# Database Configuration
POSTGRES_HOST=postgres
POSTGRES_PORT=5432
POSTGRES_DB=rag7_db
POSTGRES_USER=rag7_user
POSTGRES_PASSWORD=your-secure-password-here

# Redis Configuration
REDIS_HOST=redis
REDIS_PORT=6379
REDIS_PASSWORD=
REDIS_DB=0

# Qdrant Vector Database
QDRANT_HOST=qdrant
QDRANT_PORT=6333
QDRANT_API_KEY=

# LiteLLM Configuration
LITELLM_PROXY_URL=http://litellm-proxy:4000
LITELLM_MASTER_KEY=your-litellm-master-key
LITELLM_CACHE_TYPE=redis
LITELLM_CACHE_HOST=redis:6379

# Monitoring
PROMETHEUS_URL=http://prometheus:9090
GRAFANA_URL=http://grafana:3000
JAEGER_ENDPOINT=http://jaeger:14268/api/traces

# Application Configuration
APP_HOST=0.0.0.0
APP_PORT=8080
METRICS_PORT=9090
WORKERS=4
MAX_AGENTS=10

# Rate Limiting
RATE_LIMIT_RPM=60
RATE_LIMIT_TPM=100000

# Circuit Breaker
CIRCUIT_BREAKER_FAILURE_THRESHOLD=5
CIRCUIT_BREAKER_TIMEOUT=60
CIRCUIT_BREAKER_RECOVERY_TIMEOUT=30

# Deployment
DEPLOYMENT_ENV=dev
CLOUD_RUN_SERVICE_NAME=rag7-agent-api
GKE_CLUSTER_NAME=rag7-cluster
GKE_NAMESPACE=rag7-dev
36 changes: 36 additions & 0 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# Code Owners
# These owners will be requested for review when someone opens a pull request.

# Default owners for everything in the repo
* @Stacey77

# Source code
/src/ @Stacey77

# Tests
/tests/ @Stacey77

# CI/CD workflows
/.github/workflows/ @Stacey77

# Deployment configurations
/deploy/ @Stacey77

# Documentation
/docs/ @Stacey77
*.md @Stacey77

# Infrastructure as Code
/deploy/terraform/ @Stacey77

# Kubernetes manifests
/deploy/gke/ @Stacey77

# Monitoring and observability
/monitoring/ @Stacey77

# Dependencies
requirements*.txt @Stacey77
pyproject.toml @Stacey77
Dockerfile @Stacey77
docker-compose*.yml @Stacey77
50 changes: 50 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
version: 2
updates:
# Python dependencies
- package-ecosystem: "pip"
directory: "/"
schedule:
interval: "weekly"
day: "monday"
time: "09:00"
open-pull-requests-limit: 10
reviewers:
- "Stacey77"
labels:
- "dependencies"
- "python"
commit-message:
prefix: "chore"
include: "scope"

# Docker dependencies
- package-ecosystem: "docker"
directory: "/"
schedule:
interval: "weekly"
day: "monday"
time: "09:00"
open-pull-requests-limit: 5
reviewers:
- "Stacey77"
labels:
- "dependencies"
- "docker"
commit-message:
prefix: "chore"

# GitHub Actions
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
day: "monday"
time: "09:00"
open-pull-requests-limit: 5
reviewers:
- "Stacey77"
labels:
- "dependencies"
- "github-actions"
commit-message:
prefix: "chore"
78 changes: 78 additions & 0 deletions .github/workflows/chaos-testing.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
name: Chaos Testing

on:
schedule:
- cron: '0 2 * * 0' # Weekly on Sunday at 2 AM UTC
workflow_dispatch:

jobs:
chaos-tests:
name: Run Chaos Engineering Tests
runs-on: ubuntu-latest
environment: staging

services:
redis:
image: redis:7-alpine
ports:
- 6379:6379

postgres:
image: postgres:15-alpine
env:
POSTGRES_DB: rag7_test
POSTGRES_USER: test_user
POSTGRES_PASSWORD: test_password
ports:
- 5432:5432

steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.11'
cache: 'pip'

- name: Install dependencies
run: |
pip install -r requirements.txt -r requirements-dev.txt

- name: Run chaos tests
run: |
pytest tests/orchestration/ -v -m chaos --tb=short
env:
ENVIRONMENT: staging
REDIS_HOST: localhost
POSTGRES_HOST: localhost

- name: Generate chaos test report
if: always()
run: |
echo "# Chaos Testing Report" > chaos-report.md
echo "Date: $(date)" >> chaos-report.md
echo "" >> chaos-report.md
echo "## Test Results" >> chaos-report.md
pytest tests/orchestration/ -m chaos --tb=line --quiet >> chaos-report.md 2>&1 || true

- name: Upload chaos test report
uses: actions/upload-artifact@v4
if: always()
with:
name: chaos-test-report
path: chaos-report.md

- name: Notify on failure
if: failure()
uses: actions/github-script@v7
with:
script: |
github.rest.issues.create({
owner: context.repo.owner,
repo: context.repo.repo,
title: 'Chaos Testing Failed',
body: 'The weekly chaos testing run has failed. Please investigate.',
labels: ['chaos-testing', 'needs-investigation']
})
Loading