-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathnetlify.toml
More file actions
37 lines (30 loc) · 873 Bytes
/
netlify.toml
File metadata and controls
37 lines (30 loc) · 873 Bytes
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
[build]
base = "frontend"
publish = "frontend/build"
command = "npm run build"
[build.environment]
NODE_VERSION = "18"
NPM_VERSION = "9"
[[redirects]]
from = "/*"
to = "/index.html"
status = 200
[context.production.environment]
REACT_APP_API_URL = "https://your-backend-url.herokuapp.com"
[context.deploy-preview.environment]
REACT_APP_API_URL = "https://your-backend-url.herokuapp.com"
[context.branch-deploy.environment]
REACT_APP_API_URL = "https://your-backend-url.herokuapp.com"
# Headers for security
[[headers]]
for = "/*"
[headers.values]
X-Frame-Options = "DENY"
X-XSS-Protection = "1; mode=block"
X-Content-Type-Options = "nosniff"
Referrer-Policy = "strict-origin-when-cross-origin"
# Cache static assets
[[headers]]
for = "/static/*"
[headers.values]
Cache-Control = "public, max-age=31536000, immutable"