- PHP 7.4 support - Improved Webp images support with Cloudflare (Issue [#95](https://github.com/WordOps/WordOps/issues/95)). Nginx will not serve webp images alternative with Cloudflare IP ranges. - Stack upgrade for adminer - Check acme.sh installation and setup acme.sh if needed before issuing certificate - Add `--ufw` to `wo stack status` - Add Nginx directive `gzip_static on;` to serve precompressed assets with Cache-Enabler or WP-Rocket. (Issue [#207](https://github.com/WordOps/WordOps/issues/207)) - Previous `--php73` & `--php73=off` flags are replaced by `--php72`, `--php73`, `--php74` to switch site's php version - phpMyAdmin updated to v4.9.2 - Adminer updated to v4.7.5 - Replace dot and dashes by underscores in database names (Issue [#206](https://github.com/WordOps/WordOps/issues/206)) - Increased database name length to 32 characters from domain name + 8 random characters - typo error in motd-news script (Issue [#204](https://github.com/WordOps/WordOps/issues/204)) - Install Nginx before ngxblocker - WordOps install/update script text color - Issue with MySQL stack on Raspbian 9/10 - Typo error (PR [#205](https://github.com/WordOps/WordOps/pull/205)) - php version in `wo debug` (PR [#209](https://github.com/WordOps/WordOps/pull/209)) - SSL certificates expiration display with shared wildcard certificates
59 lines
1.9 KiB
Plaintext
59 lines
1.9 KiB
Plaintext
|
|
server {
|
|
|
|
{{#multisite}}
|
|
# Uncomment the following line for domain mapping
|
|
# listen 80 default_server;
|
|
{{/multisite}}
|
|
|
|
server_name {{site_name}} {{#multisite}}*{{/multisite}}{{^multisite}}www{{/multisite}}.{{site_name}};
|
|
|
|
{{#multisite}}
|
|
# Uncomment the following line for domain mapping
|
|
#server_name_in_redirect off;
|
|
{{/multisite}}
|
|
|
|
access_log /var/log/nginx/{{site_name}}.access.log {{^wpredis}}{{^static}}rt_cache{{/static}}{{/wpredis}}{{#wpredis}}rt_cache_redis{{/wpredis}};
|
|
error_log /var/log/nginx/{{site_name}}.error.log;
|
|
|
|
{{#proxy}}
|
|
add_header X-Proxy-Cache $upstream_cache_status;
|
|
location / {
|
|
proxy_pass http://{{host}}:{{port}};
|
|
proxy_redirect off;
|
|
proxy_set_header Host $host;
|
|
proxy_set_header X-Real-IP $remote_addr;
|
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
}
|
|
|
|
# Security settings for better privacy
|
|
# Deny hidden files
|
|
location ~ /\.(?!well-known\/) {
|
|
deny all;
|
|
}
|
|
# letsencrypt validation
|
|
location /.well-known/acme-challenge/ {
|
|
alias /var/www/html/.well-known/acme-challenge/;
|
|
allow all;
|
|
}
|
|
{{/proxy}}
|
|
|
|
{{^proxy}}
|
|
root {{webroot}}/htdocs;
|
|
|
|
index {{^static}}index.php{{/static}} index.html index.htm;
|
|
|
|
{{#static}}
|
|
location / {
|
|
try_files $uri $uri/ =404;
|
|
}
|
|
{{/static}}
|
|
|
|
{{^static}}include {{#basic}}common/{{wo_php}}.conf;{{/basic}}{{#wpfc}}common/wpfc-{{wo_php}}.conf;{{/wpfc}}{{#wpsc}}common/wpsc-{{wo_php}}.conf;{{/wpsc}}{{#wpredis}}common/redis-{{wo_php}}.conf;{{/wpredis}}{{#wprocket}}common/wprocket-{{wo_php}}.conf;{{/wprocket}}{{#wpce}}common/wpce-{{wo_php}}.conf;{{/wpce}}
|
|
{{#wpsubdir}}include common/wpsubdir.conf;{{/wpsubdir}}{{/static}}
|
|
{{#wp}}include common/wpcommon-{{wo_php}}.conf;{{/wp}}
|
|
include common/locations-wo.conf;{{/proxy}}
|
|
include {{webroot}}/conf/nginx/*.conf;
|
|
|
|
}
|