Development Environments: Dev, Test, and Prod. What are the differences?
Learn why developers use multiple servers. Understand the differences between development, testing, and production environments.
Development Environments: Dev, Test, and Prod
Imagine building a new car model. You don't test the brakes for the first time while the car is speeding down the highway with a customer at the wheel. First, you have the workshop (Dev), then the test track (Test), and finally the showroom (Prod). In the IT world, we call these stages environments.
Environment
How does it work in practice? Code Lifecycle
Code passes through several servers before reaching the end user. Each has a different purpose.
Development (Dev)
The developer's local environment. This is where code is written, experimented with, and often broken.
Test / Staging
A production copy for testers. This is where bugs are checked and progress is shown to the client (UAT).
Production (Prod)
The live organism. This is where the app serves real people and generates revenue. It must be stable.
Environment Comparison
The main differences relate to who has access to the server and what data is on it.
| Cecha | Feature | Dev |
|---|---|---|
| Users | Developers | Testers, Client |
| Data | Fake / Test | Anonymized copy |
| Stability | Low (constant changes) | High |
Common Mistakes and Pitfalls
Problem: Works on my machine!
Testing on Production
Configuration (Environment Variables)
The app needs to know which database to connect to. We use .env files for this.
DB_URL=localhost:5432
DEBUG=truePro Tips
Automate Deployments
Deployment Checklist
Before pushing to production
0/4Quiz: Check your knowledge
In which environment does the client usually perform User Acceptance Testing (UAT)?
Flowchart (Mermaid)
What's Next?
- Find out how Docker helps maintain consistency across environments.
- Check what environment variables are and why you shouldn't keep them in your code.
- Read about automation tools like GitHub Actions or Jenkins.
- Learn to create simple containers to avoid the 'works on my machine' error.
- Review INF.04 exam papers regarding website deployment.
You might also like
Relational and Logical Operators: How to Compare Data?
Understand how comparison operators work and how to combine conditions using AND, OR, and NOT. Essential knowledge for control statements.
Conditional Operator: Short-hand if-else in one line
Learn the ternary operator. Find out how to shorten your code and when to use it instead of classic if-else statements.
Mathematical Operators: The Foundation of Computing
Learn basic and advanced mathematical operators. Understand how modulo, incrementation works, and why operator precedence matters.