{"success":true,"name":"keep-dev-test-and-production-worlds-apart-never-point-your-e","description":"Developing or testing features while connected to the live database or services","category":"ai-brimind","path":"ai-brimind/keep-dev-test-and-production-worlds-apart-never-point-your-e/SKILL.md","file":"SKILL.md","content":"---\nname: keep-dev-test-and-production-worlds-apart-never-point-your-e\ndescription: \"Developing or testing features while connected to the live database or services\"\n---\n\n# Keep Dev, Test, and Production Worlds Apart: Never Point Your Editor at Real Data\n\n## When to use\nThe project has (or is about to have) real users, and development, experiments, or test scripts currently run against the same database, API keys, or services that production uses — or nothing clearly prevents that from happening by accident.\n\n## Example request\nA quick 'delete test users' script runs while the connection string points at production → real accounts vanish; the script was fine, the missing wall between worlds was the bug. Trying an email feature in dev sends real messages to real customers → external services need test modes or fake keys in dev; the env file decides which world you are in. Seed data and experiments pollute the production DB with 'test test aaa' records → analytics and lists are garbage forever; experiments belong in a disposable database. One shared .env passed around with prod credentials in it → every developer's laptop is one typo away from disaster; each environment gets its own config, and prod secrets live only where prod runs.\n\n## Instructions\nAct as an engineer who treats production like a clean room: you can look through the glass, but nothing enters or leaves casually — because every horror story that starts with 'I was just testing something' ends with real user data. Set up and verify the walls: (1) Name your environments explicitly — at minimum development (your machine, disposable data) and production (real users); staging if the project warrants a rehearsal space. Each one gets its OWN database, its OWN .env file, and its OWN external-service keys (test/sandbox keys for payment and email providers in dev — these sandbox modes exist precisely for this). (2) Make the current world visible and hard to confuse: the app should be able to tell you which environment it is in (a log line at startup, a colored banner in dev UIs), and the production connection string should not sit in your local .env at all — the best protection against pointing dev tools at prod is not having the address loaded. (3) Give dev its own seed script that builds a small, realistic dataset from zero, so wiping and rebuilding the dev DB is cheap and normal — the moment resetting dev data feels expensive, people start 'just checking things' on prod. (4) Any script that writes or deletes in bulk must state its target: make it print the database name and require confirmation, or refuse to run when the environment says production unless explicitly forced. (5) If today dev and prod share anything — a DB, a key, a bucket — treat separating them as the next task, before features: every day shared is a day one command can hurt real people. Only consider this settled once you can answer instantly: 'which world am I connected to right now, and what proves a mistake here cannot touch users?' — if the answer requires checking a connection string character by character, the wall is not built yet.\n\n## Metadata\n- role: developer\n- level: tactical\n- places: vibeCoding\n- origin: ai.brimind.pro skill #207\n","linked_files":[],"origin":"ai.brimind.pro","owner_id":null,"source":"router"}