Loading topic
Host header. By the end you should be able to predict which server block and which location block handle any given request, an5 min readserver block and know what root and location do from the earlier chapters. It also assumes you have a PHP or Python app that already runs behind some server process. The goal here is the split of work. Nginx answers requests for files that exist on di6 min readlocation are. Earlier chapters covered both, a5 min readlocation matching, and that you are on a Debian/Ubuntu-style host. The example app lives in `/srv/my5 min readserver block, Gunicorn or PHP-FPM behind it, and a domain name whose DNS record points at your server. You also need ports 80 and 443 open in the firewall and sudo acces5 min readls -l output, use chown and chmod, and write the Nginx and systemd configuration from the earlier chapters. The goal is to limit what a compromised web process can read, write, and execute. If an attacker finds a bug in your PHP or Python code, the damage shou6 min readsystemctl, file ownership, and HTTP status codes. The goal is a repeatable method for finding the cause of a failing request. Memorizing error messa5 min readsystemctl, reading logs and editing config files. Tuning is the last step. Measure first, change one setting at a time, and measure again.6 min read