diff --git a/netlify.toml b/netlify.toml new file mode 100644 index 00000000..bca5d213 --- /dev/null +++ b/netlify.toml @@ -0,0 +1,47 @@ +[build] + publishDir = "public" + +[build.environment] + HUGO_VERSION = "0.123.0" + NODE_VERSION = "20" + +[[redirects]] + from = "/docs/*" + to = "/documentation/:splat" + status = 301 + +[[redirects]] + from = "/blog/*" + to = "/blog/:splat" + status = 301 + +[[headers]] + for = "/*" + [headers.values] + X-Frame-Options = "DENY" + X-Content-Type-Options = "nosniff" + Referrer-Policy = "strict-origin-when-cross-origin" + +[[headers]] + for = "*.js" + [headers.values] + Cache-Control = "public, max-age=31536000" + +[[headers]] + for = "*.css" + [headers.values] + Cache-Control = "public, max-age=31536000" + +[[headers]] + for = "*.png" + [headers.values] + Cache-Control = "public, max-age=2592000" + +[context.production.environment] + HUGO_ENV = "production" + +[context.deploy-preview.environment] + HUGO_ENV = "preview" + +[context.branch-deploy.environment] + HUGO_ENV = "staging"