Skip to content

Commit 8348ee3

Browse files
committed
ci: upgrade hugo to v0.136.3
https://github.com/gohugoio/hugo/releases/tag/v0.136.3 Signed-off-by: David Karlsson <[email protected]>
1 parent 4b43bed commit 8348ee3

File tree

3 files changed

+12
-12
lines changed

3 files changed

+12
-12
lines changed

.dockerignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
.github
33
.gitignore
44
.idea
5+
.hugo_build.lock
56
_releaser
67
CONTRIBUTING.md
78
Dockerfile

Dockerfile

Lines changed: 10 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,10 @@ ARG GO_VERSION=1.23
88
# HTMLTEST_VERSION sets the wjdp/htmltest version for HTML testing
99
ARG HTMLTEST_VERSION=0.17.0
1010
# HUGO_VERSION sets the version of Hugo to build the site with
11-
ARG HUGO_VERSION=0.136.2
11+
ARG HUGO_VERSION=0.136.3
1212

1313
# build-base is the base stage used for building the site
1414
FROM ghcr.io/gohugoio/hugo:v${HUGO_VERSION} AS build-base
15-
USER root
1615
ENV NODE_ENV="production"
1716
RUN --mount=source=package.json,target=package.json \
1817
--mount=source=package-lock.json,target=package-lock.json \
@@ -27,7 +26,7 @@ ARG HUGO_ENV="development"
2726
# DOCS_URL sets the base URL for the site
2827
ARG DOCS_URL="https://docs.docker.com"
2928
RUN --mount=type=cache,target=/cache \
30-
hugo --gc --minify -d /out -e $HUGO_ENV -b $DOCS_URL
29+
hugo --gc --minify -e $HUGO_ENV -b $DOCS_URL
3130

3231
# lint lints markdown files
3332
FROM davidanson/markdownlint-cli2:v0.14.0 AS lint
@@ -41,7 +40,7 @@ RUN --mount=type=bind,target=. \
4140
# test validates HTML output and checks for broken links
4241
FROM wjdp/htmltest:v${HTMLTEST_VERSION} AS test
4342
WORKDIR /test
44-
COPY --from=build /out ./public
43+
COPY --from=build /project/public ./public
4544
ADD .htmltest.yml .htmltest.yml
4645
RUN htmltest
4746

@@ -76,12 +75,12 @@ ARG UPSTREAM_REPO
7675
ARG UPSTREAM_COMMIT
7776
# HUGO_MODULE_REPLACEMENTS is the replacement module for the upstream project
7877
ENV HUGO_MODULE_REPLACEMENTS="github.com/${UPSTREAM_MODULE_NAME} -> github.com/${UPSTREAM_REPO} ${UPSTREAM_COMMIT}"
79-
RUN hugo --ignoreVendorPaths "github.com/${UPSTREAM_MODULE_NAME}" -d /out
78+
RUN hugo --ignoreVendorPaths "github.com/${UPSTREAM_MODULE_NAME}"
8079

8180
# validate-upstream validates HTML output for upstream builds
8281
FROM wjdp/htmltest:v${HTMLTEST_VERSION} AS validate-upstream
8382
WORKDIR /test
84-
COPY --from=build-upstream /out ./public
83+
COPY --from=build-upstream /project/public ./public
8584
ADD .htmltest.yml .htmltest.yml
8685
RUN htmltest
8786

@@ -96,9 +95,9 @@ EOT
9695

9796
# path-warnings checks for duplicate target paths
9897
FROM build-base AS path-warnings
99-
RUN hugo --printPathWarnings > /path-warnings.txt
98+
RUN hugo --printPathWarnings > ./path-warnings.txt
10099
RUN <<EOT
101-
DUPLICATE_TARGETS=$(grep "Duplicate target paths" /path-warnings.txt)
100+
DUPLICATE_TARGETS=$(grep "Duplicate target paths" ./path-warnings.txt)
102101
if [ ! -z "$DUPLICATE_TARGETS" ]; then
103102
echo "$DUPLICATE_TARGETS"
104103
echo "You probably have a duplicate alias defined. Please check your aliases."
@@ -109,7 +108,7 @@ EOT
109108
# pagefind installs the Pagefind runtime
110109
FROM node:alpine${ALPINE_VERSION} AS pagefind
111110
ARG PAGEFIND_VERSION=1.1.1
112-
COPY --from=build /out ./public
111+
COPY --from=build /project/public ./public
113112
RUN --mount=type=bind,src=pagefind.yml,target=pagefind.yml \
114113
npx pagefind@v${PAGEFIND_VERSION} --output-path "/pagefind"
115114

@@ -121,13 +120,13 @@ COPY --from=pagefind /pagefind .
121120
FROM alpine:${ALPINE_VERSION} AS test-go-redirects
122121
WORKDIR /work
123122
RUN apk add yq
124-
COPY --from=build /out ./public
123+
COPY --from=build /project/public ./public
125124
RUN --mount=type=bind,target=. <<"EOT"
126125
set -ex
127126
./scripts/test_go_redirects.sh
128127
EOT
129128

130129
# release is an empty scratch image with only compiled assets
131130
FROM scratch AS release
132-
COPY --from=build /out /
131+
COPY --from=build /project/public /
133132
COPY --from=pagefind /pagefind /pagefind

netlify.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ publish = "public"
44
[context.deploy-preview.environment]
55
NODE_VERSION = "20"
66
NODE_ENV = "production"
7-
HUGO_VERSION = "0.136.2"
7+
HUGO_VERSION = "0.136.3"
88
HUGO_ENABLEGITINFO = "true"
99
HUGO_ENVIRONMENT = "preview"
1010

0 commit comments

Comments
 (0)