주 메뉴 열기

wwiki β

바뀜

Nginx

464 바이트 추가됨, 2023년 10월 26일 (목) 09:47
Admin Guide
== Admin Guide ==
 
=== Security Controls ===
 
==== Restricting Access with HTTP Basic Authentication ====
https://docs.nginx.com/nginx/admin-guide/security-controls/configuring-http-basic-authentication/
 
===== Creating a Password File =====
Apache와 Basic 인증으로 접근 제한하기
 
[[htpasswd]] 명령으로 만들 수 있다.
=== Web Server ===
==== NGINX Reverse Proxy (리버스 프록시) ====
https://docs.nginx.com/nginx/admin-guide/web-server/reverse-proxy/
===== Passing a Request to a Proxied Server =====
proxy_pass http://localhost:8000;
}
</syntaxhighlight>nginx는 proxy_set_header 지시어를 사용하여 프록시된 서버로 전달되는 헤더 필드를 변경하거나 제거할 수 있습니다. 이 지시어는 location, server, http 블록 등에서 지정할 수 있습니다.  위 예제에서 [[HTTP#Host|Host]]필드는 $proxy_host변수로 설정되었다. <syntaxhighlight lang="nginx">location /some/path/ { proxy_set_header Accept-Encoding ""; proxy_pass http://localhost:8000;} </syntaxhighlight>위 예제에서 Accept-Encoding 필드가 프록시된 서버로 전달되는 것을 방지하기 위하여 빈 문자열로 설정했다.  === Security Controls === ==== Restricting Access with HTTP Basic Authentication ====https://docs.nginx.com/nginx/admin-guide/security-controls/configuring-http-basic-authentication/ ===== Creating a Password File =====Apache와 Basic 인증으로 접근 제한하기 [[HTTP#Connection|Connectionhtpasswd]]을 재정의하고 empty string인 헤더 필드를 제거합니다. Host는 $proxy_host변수로 설정되고, Connection은 close로 설정된다명령으로 만들 수 있다.
== http core module ==
편집
2,431