Skip to content
Merged
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
12 changes: 8 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,10 +81,14 @@ Here is what you need to be able to run Comp AI.
bun i
```

4. Set up your `.env` file

- Duplicate `.env.example` to `.env`
- Use `openssl rand -base64 32` to generate a key and add it under `NEXTAUTH_SECRET` in the `.env` file.
4. Set up your `.env` files
- Copy the example environment files to create your local environment files:
```sh
cp apps/web/.env.example apps/web/.env
cp apps/app/.env.example apps/app/.env
```
- Fill in the required environment variables in both `.env` files
- Use `openssl rand -base64 32` to generate a key and add it under `AUTH_SECRET` in the `apps/app/.env` file

5. Setup Node
If your Node version does not meet the project's requirements as instructed by the docs, "nvm" (Node Version Manager) allows using Node at the version required by the project:
Expand Down
44 changes: 44 additions & 0 deletions apps/app/.env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
# Authentication (https://console.cloud.google.com/apis/credentials)
AUTH_SECRET="" # Generate with: openssl rand -base64 32
AUTH_GOOGLE_ID="" # Google Cloud Console -> APIs & Services -> Credentials -> Create OAuth 2.0 Client ID
AUTH_GOOGLE_SECRET="" # Google Cloud Console -> Same location as above

# Database (https://neon.tech)
DATABASE_URL="postgresql://postgres:postgres@localhost:5432/postgres" # Format: postgresql://user:password@host:port/database

# AI Services
# OpenAI (https://platform.openai.com/api-keys)
OPENAI_API_KEY="" # Get from OpenAI dashboard -> API Keys

# Email Services
# Resend (https://resend.com/api-keys)
RESEND_API_KEY="" # Resend Dashboard -> API Keys

# Infrastructure
# Redis - Upstash (https://console.upstash.com/)
UPSTASH_REDIS_REST_URL="" # Upstash Console -> Redis -> Create Database
UPSTASH_REDIS_REST_TOKEN="" # Found in the same database details page

# Payment Processing
# Stripe (https://dashboard.stripe.com/apikeys)
STRIPE_SECRET_KEY="" # Stripe Dashboard -> Developers -> API keys
STRIPE_WEBHOOK_SECRET="" # Stripe Dashboard -> Developers -> Webhooks

# File Storage
# Upload Thing (https://uploadthing.com/dashboard)
UPLOADTHING_TOKEN="" # Upload Thing Dashboard -> API Keys
UPLOADTHING_SECRET="" # Upload Thing Dashboard -> API Keys

# Integration Services
# OpenPanel (https://openpanel.dev)
OPENPANEL_SECRET_KEY="" # OpenPanel Dashboard -> Settings -> API Keys
NEXT_PUBLIC_OPENPANEL_CLIENT_ID="" # OpenPanel Dashboard -> Settings -> Client ID

# Nango (https://app.nango.dev)
NANGO_SECRET_KEY="1234567890" # Nango Dashboard -> API Keys

# Trigger.dev (https://app.trigger.dev)
TRIGGER_SECRET_KEY="" # Trigger.dev Dashboard -> Project Settings -> API Keys

# Monitoring
DISCORD_WEBHOOK_URL="" # Discord Server -> Settings -> Integrations -> Create Webhook
2 changes: 1 addition & 1 deletion apps/app/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ yarn-error.log*
.pnpm-debug.log*

# env files (can opt-in for committing if needed)
.env*
.env

# vercel
.vercel
Expand Down
17 changes: 17 additions & 0 deletions apps/web/.env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Email Services
# Resend (https://resend.com/api-keys)
RESEND_API_KEY="" # Resend Dashboard -> API Keys
RESEND_AUDIENCE_ID="" # Resend Dashboard -> Audiences

# Security & Anti-Spam
# Cloudflare Turnstile (https://dash.cloudflare.com/?to=/:account/turnstile)
TURNSTILE_SECRET_KEY="" # Cloudflare Dashboard -> Turnstile -> Your Site -> Settings
NEXT_PUBLIC_TURNSTILE_SITE_KEY="" # Same location as above

# Monitoring
# Discord (https://discord.com/developers/applications)
DISCORD_WEBHOOK_URL="" # Discord Server -> Settings -> Integrations -> Create Webhook

# Analytics
# Google Analytics (https://analytics.google.com)
NEXT_PUBLIC_GOOGLE_TAG_ID="" # GA4 -> Admin -> Data Streams -> Choose your stream -> Measurement ID
2 changes: 1 addition & 1 deletion apps/web/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ yarn-error.log*
.pnpm-debug.log*

# env files (can opt-in for committing if needed)
.env*
.env

# vercel
.vercel
Expand Down