-
Notifications
You must be signed in to change notification settings - Fork 126
/
netlify.toml
35 lines (28 loc) · 1.26 KB
/
netlify.toml
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
# https://docs.netlify.com/routing/redirects/redirect-options/#custom-404-page-handling
[[redirects]]
from = "/*"
to = "/404/"
status = 404
[build]
base = "docs/"
publish = "public/"
# On netlify our branch will always be the one we are currently building for
# important information regarding naming
# https://gohugo.io/getting-started/configuration/#configure-with-environment-variables
command = "HUGOxPARAMSxGITHUB_BRANCH=$BRANCH HUGOxPARAMSxCURRENTVERSION=$BRANCH hugo -b $DEPLOY_PRIME_URL"
ignore = "git diff --quiet $CACHED_COMMIT_REF $COMMIT_REF . ../netlify.toml"
[build.environment]
# added specifically a docker image, so the versions within makefile and netlify documentation match
# renovate: datasource=docker depName=klakegg/hugo
HUGO_VERSION = "0.111.3"
HUGO_ENABLEGITINFO = "true"
[context.deploy-preview.environment]
HUGO_ENV = "development"
[context.branch-deploy.environment]
HUGO_ENV = "staging"
[context.production]
# On netlify our branch will always be the one we are currently building for
# important information regarding naming
# https://gohugo.io/getting-started/configuration/#configure-with-environment-variables
command = "HUGOxPARAMSxGITHUB_BRANCH=$BRANCH HUGOxPARAMSxCURRENTVERSION=$BRANCH hugo -b $URL"
environment = { HUGO_ENV = "production" }