b91112516d
* Introduce Kumpir, our new www server, add wordpress role * move kumpir to services group, use safer distinction for ssl_cert location, reduce www playbook * set server type to services * fix typo * rename service-wordpress to service-nginx-wordpress * Add service-nginx-etherpad role * Add ed25519 keypair for system_users when supported. * Revert "Add ed25519 keypair for system_users when supported." This reverts commit ffef991ca41185d19953b96439e80b1b9a6ba534. * Change generated keys format to ed25519 * fix indention of nginx templates, reduce amount of needed tasks by adding extra_opts to unarchive, remove not needed mysql db tasks, make new acme_server default * Change new default preference for acme servers, marking acme_server zuckerwatte deprecated soon.
52 lines
1.3 KiB
Django/Jinja
52 lines
1.3 KiB
Django/Jinja
server {
|
|
listen 80;
|
|
listen [::]:80;
|
|
server_name {{ wp_service_name }};
|
|
return 301 https://$http_host$request_uri;
|
|
}
|
|
|
|
server {
|
|
listen 443 ssl http2;
|
|
listen [::]:443 ssl http2;
|
|
server_name {{ wp_service_name }};
|
|
|
|
ssl_certificate {{ nginx_ssl_directory }}fullchain.pem;
|
|
ssl_certificate_key {{ nginx_ssl_directory }}privkey.pem;
|
|
ssl_prefer_server_ciphers on;
|
|
|
|
|
|
root {{ wp_install_dir }};
|
|
|
|
# Add index.php to the list if you are using PHP
|
|
index index.php;
|
|
|
|
server_name {{ wp_service_name }};
|
|
|
|
client_max_body_size 1024M;
|
|
|
|
location / {
|
|
# First attempt to serve request as file, then
|
|
# as directory, then fall back to displaying a 404.
|
|
#try_files $uri $uri/ =404;
|
|
try_files $uri $uri/ /index.php$is_args$args;
|
|
}
|
|
|
|
location = /favicon.ico { log_not_found off; access_log off; }
|
|
location = /robots.txt { log_not_found off; access_log off; allow all; }
|
|
location ~* \.(css|gif|ico|jpeg|jpg|js|png)$ {
|
|
expires max;
|
|
log_not_found off;
|
|
}
|
|
|
|
# pass the PHP scripts to FastCGI server listening on socket
|
|
location ~ \.php$ {
|
|
try_files $uri =404;
|
|
include /etc/nginx/fastcgi_params;
|
|
fastcgi_read_timeout 3600s;
|
|
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
|
|
fastcgi_pass 127.0.0.1:9000;
|
|
fastcgi_split_path_info ^(.+\.php)(/.+)$;
|
|
fastcgi_index index.php;
|
|
}
|
|
|
|
}
|