1
0

Добавлена 404 страница для домашней страницы

This commit is contained in:
Anton Vakhrushev 2018-09-14 07:40:25 +03:00
parent 7e807a245c
commit daae31c044
3 changed files with 19 additions and 1 deletions

View File

@ -6,6 +6,15 @@ configure:
--ask-become-pass \ --ask-become-pass \
ansible/configuration.yml ansible/configuration.yml
configure-web-server:
ansible-playbook \
--inventory "ansible/hosts_prod" \
--extra-vars='ansible_python_interpreter=/usr/bin/python3' \
--user=av \
--ask-become-pass \
--tags webserver \
ansible/configuration.yml
dry-run: dry-run:
ansible-playbook \ ansible-playbook \
--inventory "ansible/hosts_prod" \ --inventory "ansible/hosts_prod" \

View File

@ -8,7 +8,7 @@ dependencies:
- '{{ homepage_domain }}' - '{{ homepage_domain }}'
- 'www.{{ homepage_domain }}' - 'www.{{ homepage_domain }}'
tags: tags:
- ssl - webserver
- role: blocks/static-site - role: blocks/static-site
static_site_name: '{{ homepage_name }}' static_site_name: '{{ homepage_name }}'

View File

@ -28,4 +28,13 @@ server {
index index.html; index index.html;
try_files $uri $uri/ =404; try_files $uri $uri/ =404;
} }
error_page 404 /404/;
location = /404/ {
root {{ homepage_dir }}/current;
index index.html;
try_files $uri $uri/ =409;
internal;
}
} }