Check: configuration

Knowledge check · 5 min · Module 4, lesson 5 of 55 min left in this module

Module 4 · ConfigurationLesson 5 of 5

Goal: Confirm you can keep configuration outside the code, read it safely, and predict when a change reaches a running app.

Four questions: three on Module 4 and one from Module 2. Every answer explains itself, right or wrong.

Which of these should come from the environment rather than be written in the code?
You're about to make your first commit. Your folder has server.js, .env and .env.example. What should .gitignore contain?
On ComputeSphere, you save a new variable on a running service and choose Save only. When does the app see it?
From Module 2: a client sends POST /orders with a JSON body that's missing the required quantity field. Which status code should the API return?

Retry as often as you like.