Dev Mode

Test the full KashKlaw dashboard locally without VPS Docker.io or Stripe

What is Dev Mode?

Dev mode lets you run and test the entire KashKlaw dashboard UI without needing a VPS Docker.io account or Stripe account. It's designed for local development only.

When enabled, dev mode:

  • Skips VPS Docker.io — Deploy, start, stop, restart, and delete actions update the database but don't create real machines. A fake machine ID is assigned instead.
  • Skips Stripe checkout — The landing page flow redirects straight to the dashboard instead of going through Stripe payment.
  • Shows mock subscription — The subscription page displays a fake "Pro / Active" subscription so you can test the full dashboard without paying.
  • Keeps everything else real — Auth, database operations, API key encryption, model selection, and Telegram bot token management all work normally against your Supabase instance.

How to Enable

Add this line to your .env.local file:

NEXT_PUBLIC_DEV_MODE=true

Then restart the dev server:

npm run dev

Never enable dev mode in production. It bypasses billing enforcement and machine provisioning.

Minimum .env.local for Dev Mode

With dev mode on, you only need a subset of environment variables. The VPS Docker.io and Stripe values can be placeholders:

# Required — Supabase (real values needed for auth + DB) NEXT_PUBLIC_SUPABASE_URL=https://your-project.supabase.co NEXT_PUBLIC_SUPABASE_PUBLISHABLE_KEY=your-anon-key SUPABASE_SERVICE_ROLE_KEY=your-service-role-key # Required — Encryption (any 32-char hex string) ENCRYPTION_KEY=59507c5fd561661beda5836c23654104 # Dev mode flag NEXT_PUBLIC_DEV_MODE=true # Placeholders — not used in dev mode FLY_API_TOKEN=placeholder FLY_APP_NAME=placeholder BILLING_PROVIDER=stripe STRIPE_SECRET_KEY=sk_test_placeholder NEXT_PUBLIC_STRIPE_PUBLISHABLE_KEY=pk_test_placeholder STRIPE_WEBHOOK_SECRET=whsec_placeholder NEXT_PUBLIC_SITE_URL=http://localhost:3000

What Works vs What Doesn't

FeatureDev ModeNotes
Google OAuth sign-inWorksRequires real Supabase project
Deploy instanceWorksCreates DB record with fake machine ID
Start / Stop / RestartWorksUpdates DB status, skips VPS Docker.io calls
Delete instanceWorksRemoves DB record, skips machine removal
API key managementWorksEncrypted storage works, skips machine update
Telegram bot tokenWorksToken saved, skips machine update
AI model selectionWorksPreference saved in DB
Subscription pageMockShows fake "Pro / Active" subscription
Stripe checkoutSkippedLanding flow redirects to dashboard
Visit instance URLNoNo real machine, URL won't resolve
Refresh status from VPS Docker.ioMockReturns current DB status, no VPS Docker.io query

Switching to Production

When you're ready to go live, remove or set the flag to false:

NEXT_PUBLIC_DEV_MODE=false

Then fill in real values for all environment variables (VPS Docker.io token, Stripe keys, etc.) and redeploy. See the full .env.local.example for reference.