parent
fc44b704cf
commit
a2e6e98436
|
@ -40,6 +40,7 @@ FreeBSD:
|
|||
- `nginx_resolver`: list of DNS resolver (default: OpenDNS)
|
||||
- `nginx_error_log_level`: default log level
|
||||
- `nginx_auto_config_httpv2`: boolean, auto configure HTTP2 where possible
|
||||
- `nginx_fastcgi_fix_realpath`: boolean, use realpath for fastcgi (fix problems with symlinks and PHP opcache)
|
||||
|
||||
### Nginx Configuration
|
||||
|
||||
|
|
|
@ -18,6 +18,7 @@ nginx_error_log_level: 'warn' # http://nginx.org/en/docs/ngx_core_module.html#er
|
|||
nginx_auto_config_httpv2: true
|
||||
nginx_default_vhost: null
|
||||
nginx_default_vhost_ssl: null
|
||||
nginx_fastcgi_fix_realpath: true
|
||||
|
||||
#
|
||||
# Nginx directories
|
||||
|
|
|
@ -19,3 +19,16 @@
|
|||
dest="{{ nginx_etc_dir }}/conf.d/custom.conf"
|
||||
notify: reload nginx
|
||||
|
||||
- name: LINEINFILE | Fix path
|
||||
lineinfile: >
|
||||
regexp='{{ item.0.regexp }}'
|
||||
line='{{ item.0.line }}'
|
||||
dest='{{ item.1 }}'
|
||||
with_nested:
|
||||
-
|
||||
- regexp: '^fastcgi_param SCRIPT_FILENAME'
|
||||
line: 'fastcgi_param SCRIPT_FILENAME $realpath_root$fastcgi_script_name;'
|
||||
- regexp: '^fastcgi_param DOCUMENT_ROOT'
|
||||
line: 'fastcgi_param DOCUMENT_ROOT $realpath_root;'
|
||||
- [ '/etc/nginx/fastcgi_params', '/etc/nginx/fastcgi.conf' ]
|
||||
when: nginx_fastcgi_fix_realpath
|
||||
|
|
Loading…
Reference in New Issue