Добавлена 404 страница для домашней страницы
This commit is contained in:
parent
7e807a245c
commit
daae31c044
9
Makefile
9
Makefile
@ -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" \
|
||||||
|
@ -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 }}'
|
||||||
|
@ -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;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user