-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathnetlify.toml
More file actions
66 lines (55 loc) · 2.74 KB
/
Copy pathnetlify.toml
File metadata and controls
66 lines (55 loc) · 2.74 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
# Основной блок Netlify build configuration Hugo + Tailwind CSS
[build]
publish = "public"
# Папка с результатом сборки Hugo
command = "git submodule update --init --recursive && node scripts/export_reviews.mjs && hugo --environment development --gc --minify"
# 1) Обновляем git-подмодули 2) Выгружаем approved отзывы 3) Собираем сайт Hugo с очисткой кэша и минификацией
[build.environment]
HUGO_VERSION = "0.164.0"
# Версия Hugo
HUGO_ENVIRONMENT = "development"
# Временный безопасный режим Hugo: HTML-страницы остаются noindex,nofollow
TZ = "Europe/Kyiv"
# Часовой пояс
NODE_VERSION = "24.16.0"
# Версия Node.js для сборки Tailwind
NPM_FLAGS = "--legacy-peer-deps"
# Флаг npm для предотвращения конфликтов зависимостей
# Блок Headers для безопасности, SEO и кеширования
# Fingerprinted Hugo assets можно безопасно хранить в браузере длительно.
# Стабильные URL изображений и иконок должны перепроверяться после deploy:
# атомарный deploy инвалидирует CDN Netlify, но не очищает браузерный кэш.
[[headers]]
for = "/assets/*"
[headers.values]
Cache-Control = "public, max-age=31536000, immutable"
[[headers]]
for = "/images/*"
[headers.values]
Cache-Control = "public, max-age=0, must-revalidate"
[[headers]]
for = "/*.ico"
[headers.values]
Cache-Control = "public, max-age=0, must-revalidate"
[[headers]]
for = "/*.png"
[headers.values]
Cache-Control = "public, max-age=0, must-revalidate"
[[headers]]
for = "/*.svg"
[headers.values]
Cache-Control = "public, max-age=0, must-revalidate"
[[headers]]
for = "/*.webmanifest"
[headers.values]
Cache-Control = "public, max-age=0, must-revalidate"
[[headers]]
for = "/*"
[headers.values]
X-Frame-Options = "DENY"
X-Content-Type-Options = "nosniff"
Cross-Origin-Opener-Policy = "same-origin"
Referrer-Policy = "strict-origin-when-cross-origin"
Permissions-Policy = "geolocation=(), microphone=(), camera=()"
Strict-Transport-Security = "max-age=31536000; includeSubDomains; preload"
Content-Security-Policy = "default-src 'self'; base-uri 'self'; object-src 'none'; frame-ancestors 'none'; img-src 'self' data: https:; style-src 'self' 'unsafe-inline'; script-src 'self'; font-src 'self' data:; connect-src 'self'; manifest-src 'self'; worker-src 'self'; trusted-types aerocool-service-worker; require-trusted-types-for 'script'; upgrade-insecure-requests"