Skip to content
Open
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
10 changes: 7 additions & 3 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,13 @@ NEXT_PUBLIC_ENV="production"
COLLAB_PORT="4000"
COLLAB_TRUST_PROXY="false"

# ── Inngest (background work) ────────────────────────────────────────────
# Generate each with: openssl rand -hex 32
INNGEST_EVENT_KEY=""
INNGEST_SIGNING_KEY=""
# Run dashboard on the host. The app uses the compose network, so this is host-only.
INNGEST_PORT="8288"

# ── Optional integrations ────────────────────────────────────────────────
# With SKIP_ENV_VALIDATION=true (default here), every var below can stay
# blank — the apps boot fine, but the feature behind a missing credential
Expand Down Expand Up @@ -71,9 +78,6 @@ STRIPE_PRICE_SEAT_BUSINESS=""
STRIPE_PRICE_SEAT_PRO=""
STRIPE_PORTAL_CONFIGURATION_ID=""

# Bearer token for /api/cron/* (apps/app). Generate with: openssl rand -hex 32
CRON_SECRET=""

NEXT_PUBLIC_POSTHOG_ENABLED="false"
NEXT_PUBLIC_POSTHOG_KEY=""
NEXT_PUBLIC_POSTHOG_HOST="https://eu.i.posthog.com"
16 changes: 9 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,13 +61,14 @@ ee/ # enterprise-only code, separately licensed — see ee/README.md
Fastest path — Docker:

```bash
cp .env.example .env # fill in COLLAB_TOKEN_SECRET, BETTER_AUTH_SECRET
cp .env.example .env # fill in COLLAB_TOKEN_SECRET, BETTER_AUTH_SECRET,
# INNGEST_EVENT_KEY, INNGEST_SIGNING_KEY
docker compose up -d --build
```

Spins up Postgres and all three apps in one go. Full walkthrough, including
deploying to a real domain and optional third-party integrations, is in
[docs/docker.md](docs/docker.md).
Spins up Postgres, the Inngest background-work engine, and all three apps in
one go. Full walkthrough, including deploying to a real domain and optional
third-party integrations, is in [docs/docker.md](docs/docker.md).

From source instead — Node ≥22, pnpm 10.33, a Postgres database:

Expand All @@ -80,9 +81,10 @@ pnpm dev
```

`pnpm dev` starts every app together (`apps/app` on :3001, `apps/web` on
:3000, `apps/collab` on :4000). Full walkthrough, including what each
environment variable is for and how to run a single app on its own, is in
[docs/setup.md](docs/setup.md).
:3000, `apps/collab` on :4000); `pnpm dev:inngest` alongside it starts the
Inngest dev server on :8288, which is what runs background work. Full
walkthrough, including what each environment variable is for and how to run a
single app on its own, is in [docs/setup.md](docs/setup.md).

## Contributing

Expand Down
10 changes: 7 additions & 3 deletions apps/app/.env.example
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,13 @@ AWS_ACCESS_KEY_ID=""
AWS_SECRET_ACCESS_KEY=""
MEDIA_BUCKET_NAME="startup-prod-media"

# Vercel Cron — Bearer token for /api/cron/* (required in production)
# Generate with: openssl rand -hex 32
CRON_SECRET=""
# Inngest. These defaults are the local `inngest dev` server, which runs
# unsigned and ignores both keys. Against a real server: openssl rand -hex 32
INNGEST_BASE_URL="http://localhost:8288"
INNGEST_EVENT_KEY="local-dev-event-key"
INNGEST_SIGNING_KEY="0000000000000000000000000000000000000000000000000000000000000000"
# Set "false" to talk to a real self-hosted server — the keys must then be its keys.
# INNGEST_DEV="false"

# Short-lived collaboration room token signing (minimum 32 characters).
# The exact same value must be configured for the app and collab services.
Expand Down
1 change: 1 addition & 0 deletions apps/app/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,7 @@
"concurrently": "^9.1.2",
"framer-motion": "^11.18.2",
"geist": "^1.3.1",
"inngest": "^4.18.1",
"katex": "^0.16.21",
"lottie-react": "^2.4.1",
"lucide-react": "^0.436.0",
Expand Down
168 changes: 0 additions & 168 deletions apps/app/src/app/api/cron/sync-integrations/route.test.ts

This file was deleted.

74 changes: 0 additions & 74 deletions apps/app/src/app/api/cron/sync-integrations/route.ts

This file was deleted.

24 changes: 0 additions & 24 deletions apps/app/src/app/api/cron/testing.ts

This file was deleted.

17 changes: 17 additions & 0 deletions apps/app/src/app/api/inngest/route.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
import { serve } from "inngest/next";
import { connection, type NextRequest } from "next/server";

import { inngest } from "@/lib/inngest/client";
import { inngestFunctions } from "@/server/inngest";

export const maxDuration = 300;

const handler = serve({ client: inngest, functions: inngestFunctions });

// Under `cacheComponents` a `GET` handler is prerendered unless it reaches for request-time data, and this one depends on the request headers.
export async function GET(request: NextRequest, context: unknown) {
await connection();
return handler.GET(request, context);
}

export const { POST, PUT } = handler;
Loading
Loading