Mercurial > hg > nginx-site
changeset 1521:e3d3e2ed4275
Added example configuration to mail and stream ssl modules.
author | Yaroslav Zhuravlev <yar@nginx.com> |
---|---|
date | Tue, 30 Jun 2015 17:08:34 +0300 |
parents | ed36e909bc79 |
children | ee91c95fca48 |
files | xml/en/docs/mail/ngx_mail_ssl_module.xml xml/en/docs/stream/ngx_stream_ssl_module.xml xml/ru/docs/mail/ngx_mail_ssl_module.xml xml/ru/docs/stream/ngx_stream_ssl_module.xml |
diffstat | 4 files changed, 200 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/xml/en/docs/mail/ngx_mail_ssl_module.xml Tue Jun 30 17:00:34 2015 +0300 +++ b/xml/en/docs/mail/ngx_mail_ssl_module.xml Tue Jun 30 17:08:34 2015 +0300 @@ -10,7 +10,7 @@ <module name="Module ngx_mail_ssl_module" link="/en/docs/mail/ngx_mail_ssl_module.html" lang="en" - rev="7"> + rev="8"> <section id="summary"> @@ -32,6 +32,55 @@ </section> +<section id="example" name="Example Configuration"> + +<para> +To reduce the processor load, it is recommended to +<list type="bullet"> + +<listitem> +set the number of worker processes equal to the number of processors, +</listitem> + +<listitem> +enable the shared session cache, +</listitem> + +<listitem> +disable the built-in session cache, +</listitem> + +<listitem> +and possibly increase the session lifetime (by default, 5 minutes): +</listitem> + +</list> + +<example> +<emphasis>worker_processes auto;</emphasis> + +mail { + + ... + + server { + listen 993 ssl; + + ssl_protocols TLSv1 TLSv1.1 TLSv1.2; + ssl_ciphers AES128-SHA:AES256-SHA:RC4-SHA:DES-CBC3-SHA:RC4-MD5; + ssl_certificate /usr/local/nginx/conf/cert.pem; + ssl_certificate_key /usr/local/nginx/conf/cert.key; + <emphasis>ssl_session_cache shared:SSL:10m;</emphasis> + <emphasis>ssl_session_timeout 10m;</emphasis> + + ... + } +</example> +</para> + +</section> + + <section id="directives" name="Directives"> <directive name="ssl">
--- a/xml/en/docs/stream/ngx_stream_ssl_module.xml Tue Jun 30 17:00:34 2015 +0300 +++ b/xml/en/docs/stream/ngx_stream_ssl_module.xml Tue Jun 30 17:08:34 2015 +0300 @@ -9,7 +9,7 @@ <module name="Module ngx_stream_ssl_module" link="/en/docs/stream/ngx_stream_ssl_module.html" lang="en" - rev="4"> + rev="5"> <section id="summary"> @@ -25,6 +25,55 @@ </section> +<section id="example" name="Example Configuration"> + +<para> +To reduce the processor load, it is recommended to +<list type="bullet"> + +<listitem> +set the number of worker processes equal to the number of processors, +</listitem> + +<listitem> +enable the shared session cache, +</listitem> + +<listitem> +disable the built-in session cache, +</listitem> + +<listitem> +and possibly increase the session lifetime (by default, 5 minutes): +</listitem> + +</list> + +<example> +<emphasis>worker_processes auto;</emphasis> + +stream { + + ... + + server { + listen 12345 ssl; + + ssl_protocols TLSv1 TLSv1.1 TLSv1.2; + ssl_ciphers AES128-SHA:AES256-SHA:RC4-SHA:DES-CBC3-SHA:RC4-MD5; + ssl_certificate /usr/local/nginx/conf/cert.pem; + ssl_certificate_key /usr/local/nginx/conf/cert.key; + <emphasis>ssl_session_cache shared:SSL:10m;</emphasis> + <emphasis>ssl_session_timeout 10m;</emphasis> + + ... + } +</example> +</para> + +</section> + + <section id="directives" name="Directives"> <directive name="ssl_certificate">
--- a/xml/ru/docs/mail/ngx_mail_ssl_module.xml Tue Jun 30 17:00:34 2015 +0300 +++ b/xml/ru/docs/mail/ngx_mail_ssl_module.xml Tue Jun 30 17:08:34 2015 +0300 @@ -10,7 +10,7 @@ <module name="Модуль ngx_mail_ssl_module" link="/ru/docs/mail/ngx_mail_ssl_module.html" lang="ru" - rev="7"> + rev="8"> <section id="summary"> @@ -32,6 +32,55 @@ </section> +<section id="example" name="Пример конфигурации"> + +<para> +Для уменьшения загрузки процессора рекомендуется +<list type="bullet"> + +<listitem> +установить число рабочих процессов равным числу процессоров, +</listitem> + +<listitem> +включить разделяемый кэш сессий, +</listitem> + +<listitem> +выключить встроенный кэш сессий +</listitem> + +<listitem> +и, возможно, увеличить время жизни сессии (по умолчанию 5 минут): +</listitem> + +</list> + +<example> +<emphasis>worker_processes auto;</emphasis> + +mail { + + ... + + server { + listen 993 ssl; + + ssl_protocols TLSv1 TLSv1.1 TLSv1.2; + ssl_ciphers AES128-SHA:AES256-SHA:RC4-SHA:DES-CBC3-SHA:RC4-MD5; + ssl_certificate /usr/local/nginx/conf/cert.pem; + ssl_certificate_key /usr/local/nginx/conf/cert.key; + <emphasis>ssl_session_cache shared:SSL:10m;</emphasis> + <emphasis>ssl_session_timeout 10m;</emphasis> + + ... + } +</example> +</para> + +</section> + + <section id="directives" name="Директивы"> <directive name="ssl">
--- a/xml/ru/docs/stream/ngx_stream_ssl_module.xml Tue Jun 30 17:00:34 2015 +0300 +++ b/xml/ru/docs/stream/ngx_stream_ssl_module.xml Tue Jun 30 17:08:34 2015 +0300 @@ -9,7 +9,7 @@ <module name="Модуль ngx_stream_ssl_module" link="/ru/docs/stream/ngx_stream_ssl_module.html" lang="ru" - rev="4"> + rev="5"> <section id="summary"> @@ -25,6 +25,55 @@ </section> +<section id="example" name="Пример конфигурации"> + +<para> +Для уменьшения загрузки процессора рекомендуется +<list type="bullet"> + +<listitem> +установить число рабочих процессов равным числу процессоров, +</listitem> + +<listitem> +включить разделяемый кэш сессий, +</listitem> + +<listitem> +выключить встроенный кэш сессий +</listitem> + +<listitem> +и, возможно, увеличить время жизни сессии (по умолчанию 5 минут): +</listitem> + +</list> + +<example> +<emphasis>worker_processes auto;</emphasis> + +stream { + + ... + + server { + listen 12345 ssl; + + ssl_protocols TLSv1 TLSv1.1 TLSv1.2; + ssl_ciphers AES128-SHA:AES256-SHA:RC4-SHA:DES-CBC3-SHA:RC4-MD5; + ssl_certificate /usr/local/nginx/conf/cert.pem; + ssl_certificate_key /usr/local/nginx/conf/cert.key; + <emphasis>ssl_session_cache shared:SSL:10m;</emphasis> + <emphasis>ssl_session_timeout 10m;</emphasis> + + ... + } +</example> +</para> + +</section> + + <section id="directives" name="Директивы"> <directive name="ssl_certificate">