_CORE
AI & Agentic Systems Core Information Systems Cloud & Platform Engineering Data Platform & Integration Security & Compliance QA, Testing & Observability IoT, Automation & Robotics Mobile & Digital Banking & Finance Insurance Public Administration Defense & Security Healthcare Energy & Utilities Telco & Media Manufacturing Logistics & E-commerce Retail & Loyalty
References Technologies Blog Know-how Tools
About Collaboration Careers
CS EN
Let's talk

Nginx konfigurace od nuly

04. 04. 2018 1 min read beginner

Nginx je nejpopulárnější web server. Event-driven architektura zvládá tisíce spojení.

Installation

sudo apt install nginx sudo systemctl enable –now nginx

Virtual host

server { listen 80; server_name myapp.example.com; root /var/www/myapp; location /static/ { expires 30d; } location / { try_files $uri $uri/ /index.html; } } ln -s /etc/nginx/sites-available/myapp.conf /etc/nginx/sites-enabled/ nginx -t && systemctl reload nginx

Performance

worker_processes auto; events { worker_connections 4096; use epoll; } http { sendfile on; tcp_nopush on; gzip on; }

Security

add_header X-Content-Type-Options nosniff; add_header X-Frame-Options SAMEORIGIN; add_header Strict-Transport-Security “max-age=31536000” always;

Nginx je standard

Výchozí volba pro web serving i reverse proxy.

nginxweb serverkonfigurace
Share:

CORE SYSTEMS tým

Stavíme core systémy a AI agenty, které drží provoz. 15 let zkušeností s enterprise IT.