KCNA Cloud Native Architecture Practice Question
Which THREE are core principles of the Twelve-Factor App methodology?
⚠ Common exam trap
CNCF often tests the misconception that storing configuration in the codebase provides traceability, but the Twelve-Factor App explicitly forbids this to maintain strict separation of config from code and avoid accidental exposure of secrets.
Answer choices
Why each option matters
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
✓
Explicitly declare and isolate dependencies
The Twelve-Factor App methodology mandates that dependencies must be explicitly declared and isolated via a dependency declaration manifest (e.g., Gemfile, package.json, requirements.txt) and a dependency isolation tool (e.g., Bundler, npm, pip). This ensures that the application never implicitly depends on system-wide packages, eliminating 'it works on my machine' issues and guaranteeing consistent behavior across all environments.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
Store config in codebase for traceability
Why it's wrong here
Config should be in environment variables.
- ✓
Explicitly declare and isolate dependencies
Why this is correct
Dependencies declared in manifest.
- ✗
Tight coupling to backing services
Why it's wrong here
Backing services are attached resources.
- ✓
Treat logs as event streams
Why this is correct
Logs are aggregated, not managed by app.
- ✓
One codebase tracked in revision control, many deploys
Why this is correct
Codebase per app.
Go deeper
Related to this question
About these practice questions
Courseiva writes every KCNA question from scratch — 833 in total, each with an explanation and a wrong-answer breakdown. None are copied from real exams or dumps. Learn why practice questions differ from exam dumps →
Same concept, more angles
6 more ways this is tested on KCNA
These questions test the same concept from different angles. Work through them to make sure you can recognise it however the exam phrases it.
Variation 1. In the context of the 12-factor app methodology, which factor emphasizes storing configuration in environment variables?
easy- A.Backing services
- B.Dependencies
- ✓ C.Config
- D.Codebase
Why C: Factor III of the 12-factor app methodology states that config should be stored in environment variables to keep it separate from code.
Variation 2. In the context of the 12-factor app methodology, which factor requires that an app's configuration be stored in environment variables?
hard- ✓ A.Config
- B.Dependencies
- C.Codebase
- D.Backing services
Why A: Factor III (Config) states that configuration should be stored in environment variables to decouple it from code.
Variation 3. In the 12-factor app methodology, which factor describes the practice of storing configuration in environment variables?
medium- A.Backing services
- ✓ B.Config
- C.Processes
- D.Build, release, run
Why B: The Config factor (Factor III) of the 12-factor app methodology mandates that configuration—such as database URLs, credentials, or feature flags—be stored in environment variables. This decouples configuration from code, allowing the same build to be deployed across different environments without code changes, and prevents accidental commits of secrets to version control.
Variation 4. Which of the following is a key principle of the 12-factor app methodology related to managing configuration?
hard- A.Store configuration in the application code
- ✓ B.Use environment variables for configuration
- C.Embed configuration in the build process
- D.Use a configuration file in the application directory
Why B: The 12-factor app methodology states that configuration should be stored in environment variables (or external to the code) to vary between deployments without changing code. Hardcoding is the opposite. ConfigMaps are Kubernetes-specific but the principle is broader. Secrets are for sensitive data but not the only way.
Variation 5. Which of the following is a core principle of the 12-factor app methodology?
easy- ✓ A.Treat logs as event streams
- B.Store configuration in the application code
- C.Store logs in the local filesystem of each container
- D.Use shared filesystems for persistent storage
Why A: The 12-factor app methodology emphasizes treating logs as event streams, not files, to enable centralized processing.
Variation 6. Which TWO of the following are core principles of the 12-factor app methodology? (Select TWO.)
medium- A.Manual approval for all production deployments
- B.Use of a single programming language across all services
- C.Store logs in a local file system
- ✓ D.Strict separation of config from code
- ✓ E.Maximize robustness through fast startup and graceful shutdown
Why D: The 12-factor app methodology mandates strict separation of config from code. Config includes things like database connection strings, API keys, and environment-specific values that vary between deployments. Storing these in environment variables (or external config files not checked into version control) ensures that the same codebase can be deployed to different environments without modification, which is a core principle for cloud-native portability and security.
JA
Written by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
This KCNA practice question is part of Courseiva's free CNCF certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the KCNA exam.