2014-08-21 22:41:31 +02:00
|
|
|
---
|
2015-02-25 14:59:24 +01:00
|
|
|
# Used only for Debian/Ubuntu installation, as the -t option for apt.
|
|
|
|
nginx_default_release: ""
|
|
|
|
|
2017-01-25 17:49:27 +01:00
|
|
|
# Used only for Redhat installation, enables source Nginx repo.
|
|
|
|
nginx_yum_repo_enabled: true
|
|
|
|
|
2016-03-26 04:15:25 +01:00
|
|
|
# Use the official Nginx PPA for Ubuntu, and the version to use if so.
|
|
|
|
nginx_ppa_use: false
|
|
|
|
nginx_ppa_version: stable
|
|
|
|
|
2017-06-13 02:41:39 +02:00
|
|
|
# The name of the nginx package to install.
|
2016-02-11 12:48:09 +01:00
|
|
|
nginx_package_name: "nginx"
|
|
|
|
|
2019-06-06 18:33:04 +02:00
|
|
|
nginx_service_state: started
|
|
|
|
nginx_service_enabled: true
|
|
|
|
|
2017-03-25 21:46:37 +01:00
|
|
|
nginx_conf_template: "nginx.conf.j2"
|
|
|
|
nginx_vhost_template: "vhost.j2"
|
|
|
|
|
2018-09-26 05:42:06 +02:00
|
|
|
nginx_worker_processes: >-
|
|
|
|
"{{ ansible_processor_vcpus | default(ansible_processor_count) }}"
|
2015-02-21 06:17:13 +01:00
|
|
|
nginx_worker_connections: "1024"
|
2016-03-17 15:46:59 +01:00
|
|
|
nginx_multi_accept: "off"
|
2015-02-25 04:10:22 +01:00
|
|
|
|
|
|
|
nginx_error_log: "/var/log/nginx/error.log warn"
|
2017-08-08 19:06:19 +02:00
|
|
|
nginx_access_log: "/var/log/nginx/access.log main buffer=16k flush=2m"
|
2015-02-25 04:10:22 +01:00
|
|
|
|
|
|
|
nginx_sendfile: "on"
|
|
|
|
nginx_tcp_nopush: "on"
|
|
|
|
nginx_tcp_nodelay: "on"
|
|
|
|
|
2014-12-03 21:11:18 +01:00
|
|
|
nginx_keepalive_timeout: "65"
|
2015-02-25 04:10:22 +01:00
|
|
|
nginx_keepalive_requests: "100"
|
|
|
|
|
2017-01-30 23:40:11 +01:00
|
|
|
nginx_server_tokens: "on"
|
|
|
|
|
2015-02-25 04:10:22 +01:00
|
|
|
nginx_client_max_body_size: "64m"
|
2015-02-21 06:17:35 +01:00
|
|
|
|
2016-05-06 18:13:17 +02:00
|
|
|
nginx_server_names_hash_bucket_size: "64"
|
|
|
|
|
2015-02-21 07:02:51 +01:00
|
|
|
nginx_proxy_cache_path: ""
|
|
|
|
|
2016-02-11 12:48:09 +01:00
|
|
|
nginx_extra_conf_options: ""
|
|
|
|
# Example extra main options, used within the main nginx's context:
|
|
|
|
# nginx_extra_conf_options: |
|
|
|
|
# env VARIABLE;
|
|
|
|
# include /etc/nginx/main.d/*.conf;
|
|
|
|
|
2015-12-28 17:01:42 +01:00
|
|
|
nginx_extra_http_options: ""
|
|
|
|
# Example extra http options, printed inside the main server http config:
|
|
|
|
# nginx_extra_http_options: |
|
2015-12-22 17:11:35 +01:00
|
|
|
# proxy_buffering off;
|
|
|
|
# proxy_set_header X-Real-IP $remote_addr;
|
|
|
|
# proxy_set_header X-Scheme $scheme;
|
|
|
|
# proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
2015-12-28 16:57:11 +01:00
|
|
|
# proxy_set_header Host $http_host;
|
2015-12-22 16:59:05 +01:00
|
|
|
|
2014-08-21 22:41:31 +02:00
|
|
|
nginx_remove_default_vhost: false
|
2015-02-21 06:34:31 +01:00
|
|
|
nginx_vhosts: []
|
2015-02-21 07:02:51 +01:00
|
|
|
# Example vhost below, showing all available options:
|
2017-06-03 15:46:33 +02:00
|
|
|
# - listen: "80" # default: "80"
|
2015-09-03 23:24:58 +02:00
|
|
|
# server_name: "example.com" # default: N/A
|
|
|
|
# root: "/var/www/example.com" # default: N/A
|
|
|
|
# index: "index.html index.htm" # default: "index.html index.htm"
|
2018-09-26 05:42:06 +02:00
|
|
|
# filename: "example.com.conf" # Can be used to set the vhost filename.
|
2015-02-21 07:02:51 +01:00
|
|
|
#
|
|
|
|
# # Properties that are only added if defined:
|
2017-06-03 15:56:03 +02:00
|
|
|
# server_name_redirect: "www.example.com" # default: N/A
|
2015-09-03 23:24:58 +02:00
|
|
|
# error_page: ""
|
|
|
|
# access_log: ""
|
2015-12-28 14:10:15 +01:00
|
|
|
# error_log: ""
|
2015-05-12 22:18:50 +02:00
|
|
|
# extra_parameters: "" # Can be used to add extra config blocks (multiline).
|
2017-04-27 02:36:32 +02:00
|
|
|
# template: "" # Can be used to override the `nginx_vhost_template` per host.
|
2017-03-25 21:29:15 +01:00
|
|
|
# state: "absent" # To remove the vhost configuration.
|
2015-02-21 07:42:51 +01:00
|
|
|
|
|
|
|
nginx_upstreams: []
|
2015-09-03 23:24:58 +02:00
|
|
|
# - name: myapp1
|
|
|
|
# strategy: "ip_hash" # "least_conn", etc.
|
2016-08-08 16:35:47 +02:00
|
|
|
# keepalive: 16 # optional
|
2015-02-21 07:42:51 +01:00
|
|
|
# servers: {
|
|
|
|
# "srv1.example.com",
|
|
|
|
# "srv2.example.com weight=3",
|
|
|
|
# "srv3.example.com"
|
|
|
|
# }
|
2017-01-31 05:29:33 +01:00
|
|
|
|
2018-10-04 19:41:35 +02:00
|
|
|
nginx_log_format: |-
|
2016-11-23 14:41:16 +01:00
|
|
|
'$remote_addr - $remote_user [$time_local] "$request" '
|
|
|
|
'$status $body_bytes_sent "$http_referer" '
|
|
|
|
'"$http_user_agent" "$http_x_forwarded_for"'
|