What it is
Deployment runs an application in an environment with its own configuration, network routes, storage, and process lifecycle. Browser code is delivered to users; server code and secrets must remain on trusted infrastructure.
Why you need it
A local success can hide missing environment values, a different API origin, or data stored only in process memory. A deployed app must survive restarts and cooperate with older browser tabs.
How it works
- Build and identify the artifact being released.
- Provide environment configuration and server-only secrets.
- Apply compatible schema changes and start the service.
- Verify a real user journey, health signals, and a recovery route.
Configuration boundaries
Browser-visible:
API_BASE_URL=https://app.example.test/api
Server-only:
DATABASE_URL=<injected securely>
SESSION_SECRET=<injected securely>
Durable store:
users, sessions, orders
Process memory:
temporary caches only when safe to loseThe example uses placeholders, not real credentials. A build-time public environment variable can end up in browser assets even if the file that supplied it was not committed.
Good practices and why
- Verify the exact released artifact and keep secrets out of browser bundles and logs.
- Test restarts and compatible rollout behavior, including old clients.
Common mistakes
- Using process-local session state across multiple instances without accepting its limitations.
- Assuming changing a server variable updates an already-built browser bundle.
Try it yourself
Create a deployment checklist for a small authenticated task app. Classify each configuration value as public or server-only and name what must survive a restart.
What a successful result looks like
No credential is assigned to browser configuration, and the plan covers persistence, a smoke test, and rollback constraints.
0 / 6000 characters · Saved on this device. Do not include passwords or private data.
Check your understanding
Answer the understanding check correctly to record exercise completion.
Related interview practice
- The new schema breaks the old servers. ↗
- The API works in a command-line client but fails in the browser. ↗
- The tested build is not the deployed build. ↗
These scenarios add constraints and follow-up questions to the concepts you just learned.
Further reading
Selected primary references · reviewed 2026-10-09. Examples are educational; use your framework’s documented integration guidance when building a deployed system.