Recall & Review
beginner
What is the main configuration file for Nginx?
The main configuration file for Nginx is
nginx.conf. It controls how Nginx behaves and serves content.Click to reveal answer
beginner
What directive defines the port Nginx listens on?
The
listen directive inside a server block sets the port Nginx listens on, for example, listen 80; for HTTP.Click to reveal answer
beginner
What is a
server block in Nginx configuration?A
server block defines a virtual server. It groups settings like domain names, ports, and root folders for serving websites.Click to reveal answer
beginner
How do you specify the folder where Nginx serves files from?
Use the
root directive inside a server or location block to set the folder path, e.g., root /var/www/html;.Click to reveal answer
beginner
What command reloads Nginx after changing its configuration?
Run
sudo nginx -s reload to reload Nginx and apply configuration changes without stopping the server.Click to reveal answer
Which directive sets the port Nginx listens on?
✗ Incorrect
The
listen directive tells Nginx which port to listen on.Where do you define the domain names Nginx should respond to?
✗ Incorrect
The
server_name directive lists domain names Nginx will serve.What is the purpose of the
root directive?✗ Incorrect
The
root directive tells Nginx where to find the website files.Which command reloads Nginx configuration without stopping the server?
✗ Incorrect
The
reload signal applies config changes without downtime.What block groups settings like domain, port, and root folder in Nginx?
✗ Incorrect
The
server block defines a virtual server with its settings.Describe the basic structure of a first Nginx configuration to serve a website on port 80.
Think about how to tell Nginx what port, domain, and folder to use.
You got /5 concepts.
Explain how to apply changes after editing the Nginx configuration file.
What command lets Nginx use new settings without stopping?
You got /3 concepts.