Multi-Tenant Payload CMS for complex care solutions gmbh et al.
Find a file
Martin Porwoll 06999b2bd7 fix: add allowedOrigins for Next.js server actions behind reverse proxy
Next.js has its own CSRF protection for server actions, separate from
Payload's csrf config. Without allowedOrigins, server actions from the
admin panel behind a reverse proxy are rejected because the Origin header
(cms.c2sgmbh.de) doesn't match the Host header (localhost:3001).

Also removes temporary debug logging from multiTenant access check.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-25 13:02:03 +00:00
.claude chore: add Claude Code config, prompts, and tenant setup scripts 2026-01-18 10:18:05 +00:00
.github deps(actions): bump actions/setup-node from 4 to 6 (#17) 2026-02-23 10:06:27 +01:00
.vscode Initial commit 2025-11-26 21:18:31 +00:00
backups chore: add jobs, backups, and migration history 2025-12-01 08:24:26 +00:00
docs chore: add zweitmeinung migration docs and GitHub protection script 2026-02-23 07:16:15 +00:00
prompts chore: add Claude Code config, prompts, and tenant setup scripts 2026-01-18 10:18:05 +00:00
scripts chore: add zweitmeinung migration docs and GitHub protection script 2026-02-23 07:16:15 +00:00
src fix: add allowedOrigins for Next.js server actions behind reverse proxy 2026-02-25 13:02:03 +00:00
temp-seed-media chore: add Claude Code config, prompts, and tenant setup scripts 2026-01-18 10:18:05 +00:00
tests fix: stabilize guard responses and validation typing 2026-02-17 11:47:55 +00:00
.env.example feat: security hardening, monitoring improvements, and API guards 2026-02-17 11:42:56 +00:00
.gitignore chore: add blogwoman seed script, ignore playwright-mcp 2026-02-13 21:07:02 +00:00
.gitleaks.toml feat: implement security hardening module 2025-12-07 23:04:14 +00:00
.npmrc Initial commit 2025-11-26 21:18:31 +00:00
.prettierrc chore: update core configuration and dependencies 2025-12-01 08:18:41 +00:00
.prettierrc.json Initial commit 2025-11-26 21:18:31 +00:00
.yarnrc Initial commit 2025-11-26 21:18:31 +00:00
CLAUDE.md docs: update CLAUDE.md tech stack versions after dependency updates 2026-02-23 10:36:26 +00:00
docker-compose.yml Initial commit 2025-11-26 21:18:31 +00:00
Dockerfile Initial commit 2025-11-26 21:18:31 +00:00
drizzle.ci.config.ts fix(ci): use drizzle-kit push instead of migrations 2025-12-16 15:36:03 +00:00
drizzle.production.config.ts feat: add automatic schema sync to deployment workflow 2025-12-27 20:17:47 +00:00
ecosystem.config.cjs feat(monitoring): add snapshot collector to queue worker 2026-02-15 00:34:28 +00:00
eslint.config.mjs fix: resolve all ESLint errors for clean CI pipeline 2026-02-13 22:24:12 +00:00
next.config.mjs fix: add allowedOrigins for Next.js server actions behind reverse proxy 2026-02-25 13:02:03 +00:00
package.json deps: update remaining dependencies (react, dev-tools, bullmq) 2026-02-23 09:15:25 +00:00
playwright.config.ts test: add E2E tests for critical flows 2025-12-12 22:32:55 +00:00
pnpm-lock.yaml deps: update remaining dependencies (react, dev-tools, bullmq) 2026-02-23 09:15:25 +00:00
README.md docs: consolidate and update documentation for Payload 3.76.1 / Next.js 16 2026-02-13 21:29:50 +00:00
test.env Initial commit 2025-11-26 21:18:31 +00:00
tsconfig.json fix: resolve ESLint circular structure crash and tsc OOM 2026-02-13 22:13:45 +00:00
vercel.json feat(youtube): add metrics sync cron endpoints 2026-02-14 13:27:05 +00:00
vitest.config.mts fix(ci): add timeouts to prevent 6-hour hangs 2025-12-16 21:48:58 +00:00
vitest.setup.ts Initial commit 2025-11-26 21:18:31 +00:00

Payload CMS Multi-Tenant

Multi-Tenant Headless CMS for 3 active websites under a single Payload CMS instance.

Tech Stack

  • CMS: Payload CMS 3.76.1
  • Framework: Next.js 16.2.0-canary.41
  • Runtime: Node.js 22.x
  • Database: PostgreSQL 17.6 (via PgBouncer)
  • Cache: Redis 7.x (optional, with in-memory fallback)
  • Package Manager: pnpm

Tenants

Tenant Slug Domain
porwoll.de porwoll porwoll.de
Complex Care Solutions GmbH c2s complexcaresolutions.de
Gunshin gunshin gunshin.de

Quick Start

Prerequisites

  • Node.js 22.x
  • pnpm
  • PostgreSQL 17 (or PgBouncer connection)
  • Redis (optional)

Setup

# Install dependencies
pnpm install

# Copy environment variables
cp .env.example .env
# Edit .env with your database credentials

# Run development server
pnpm dev

Open http://localhost:3000/admin to access the admin panel.

Commands

pnpm dev                    # Development server
pnpm build                  # Production build
pnpm payload migrate        # Run migrations
pnpm payload migrate:create # Create migration
pnpm test                   # Run tests
pnpm lint                   # ESLint
pnpm typecheck              # TypeScript check

Documentation

  • CLAUDE.md - Full project documentation (collections, blocks, APIs, architecture)
  • docs/ - Additional documentation (infrastructure, deployment, security)

Email Testing

Set EMAIL_DELIVERY_DISABLED=true to bypass SMTP calls during testing. This flag is automatically honored in NODE_ENV=test.