main.yml 2.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980
  1. ---
  2. # Used only for Debian/Ubuntu installation, as the -t option for apt.
  3. nginx_default_release: ""
  4. # Used only for Redhat installation, enables source Nginx repo.
  5. nginx_yum_repo_enabled: true
  6. # Use the official Nginx PPA for Ubuntu, and the version to use if so.
  7. nginx_ppa_use: false
  8. nginx_ppa_version: stable
  9. # The name of the nginx apt/yum package to install.
  10. nginx_package_name: "nginx"
  11. nginx_worker_processes: "{{ ansible_processor_vcpus | default(ansible_processor_count) }}"
  12. nginx_worker_connections: "1024"
  13. nginx_multi_accept: "off"
  14. nginx_error_log: "/var/log/nginx/error.log warn"
  15. nginx_access_log: "/var/log/nginx/access.log main buffer=16k"
  16. nginx_sendfile: "on"
  17. nginx_tcp_nopush: "on"
  18. nginx_tcp_nodelay: "on"
  19. nginx_keepalive_timeout: "65"
  20. nginx_keepalive_requests: "100"
  21. nginx_server_tokens: "on"
  22. nginx_client_max_body_size: "64m"
  23. nginx_server_names_hash_bucket_size: "64"
  24. nginx_proxy_cache_path: ""
  25. nginx_extra_conf_options: ""
  26. # Example extra main options, used within the main nginx's context:
  27. # nginx_extra_conf_options: |
  28. # env VARIABLE;
  29. # include /etc/nginx/main.d/*.conf;
  30. nginx_extra_http_options: ""
  31. # Example extra http options, printed inside the main server http config:
  32. # nginx_extra_http_options: |
  33. # proxy_buffering off;
  34. # proxy_set_header X-Real-IP $remote_addr;
  35. # proxy_set_header X-Scheme $scheme;
  36. # proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
  37. # proxy_set_header Host $http_host;
  38. nginx_remove_default_vhost: false
  39. nginx_vhosts_filename: "vhosts.conf"
  40. nginx_vhosts: []
  41. # Example vhost below, showing all available options:
  42. # - listen: "80 default_server" # default: "80 default_server"
  43. # server_name: "example.com" # default: N/A
  44. # root: "/var/www/example.com" # default: N/A
  45. # index: "index.html index.htm" # default: "index.html index.htm"
  46. #
  47. # # Properties that are only added if defined:
  48. # error_page: ""
  49. # access_log: ""
  50. # error_log: ""
  51. # extra_parameters: "" # Can be used to add extra config blocks (multiline).
  52. nginx_upstreams: []
  53. # - name: myapp1
  54. # strategy: "ip_hash" # "least_conn", etc.
  55. # keepalive: 16 # optional
  56. # servers: {
  57. # "srv1.example.com",
  58. # "srv2.example.com weight=3",
  59. # "srv3.example.com"
  60. # }
  61. nginx_log_format: |
  62. '$remote_addr - $remote_user [$time_local] "$request" '
  63. '$status $body_bytes_sent "$http_referer" '
  64. '"$http_user_agent" "$http_x_forwarded_for"'