From 3af90d6fdc515359c7741040591ad45e31ef6ad4 Mon Sep 17 00:00:00 2001 From: Markus Spiekermann Date: Thu, 30 Oct 2025 09:20:28 +0000 Subject: [PATCH 01/23] chores: remove duplicate config --- config.yaml | 15 --------------- 1 file changed, 15 deletions(-) delete mode 100644 config.yaml diff --git a/config.yaml b/config.yaml deleted file mode 100644 index 9070e38..0000000 --- a/config.yaml +++ /dev/null @@ -1,15 +0,0 @@ -# THIS IS A TEST CONFIG ONLY! -# FOR THE CONFIGURATION OF YOUR SITE USE hugo.yaml. -# -# As of Docsy 0.7.0, Hugo 0.110.0 or later must be used. -# -# The sole purpose of this config file is to detect Hugo-module builds that use -# an older version of Hugo. -# -# DO NOT add any config parameters to this file. You can safely delete this file -# if your project is using the required Hugo version. - -module: - hugoVersion: - extended: true - min: 0.110.0 From 70b336c1711fc4e0b4b1dbac278116e2e1b57219 Mon Sep 17 00:00:00 2001 From: Markus Spiekermann Date: Thu, 30 Oct 2025 09:46:24 +0000 Subject: [PATCH 02/23] remove npm deployment and use docker for dev and live --- .github/workflows/publish.yml | 76 +++++++++++++++++------------------ Dockerfile | 8 ++-- docker-compose.yaml | 13 +++--- docsy.work | 5 --- docsy.work.sum | 0 go.mod | 8 ++-- package.json | 43 +++----------------- 7 files changed, 57 insertions(+), 96 deletions(-) delete mode 100644 docsy.work delete mode 100644 docsy.work.sum diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 33b6dfa..607a14d 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -1,60 +1,58 @@ -name: publish +name: Build & Deploy (Docker) on: push: - branches: - - main + branches: [ main ] workflow_dispatch: +permissions: + contents: read + pages: write + id-token: write + +concurrency: + group: pages + cancel-in-progress: true + jobs: build: runs-on: ubuntu-latest + container: floryn90/hugo:0.124.0-ext-alpine steps: - uses: actions/checkout@v4 - with: - submodules: true # Fetch Hugo themes (true OR recursive) - fetch-depth: 0 # Fetch all history for .GitInfo and .Lastmod - - uses: actions/setup-node@v4 - - run: npm i -D postcss postcss-cli autoprefixer - - name: Setup Hugo - uses: peaceiris/actions-hugo@v3 - with: - hugo-version: "0.134.1" - extended: true - - name: Build - run: hugo --minify + - name: Install PostCSS deps (inside container) + run: | + apk add --no-cache nodejs npm git + npm install -g postcss postcss-cli autoprefixer + git config --global --add safe.directory $GITHUB_WORKSPACE + + - name: Cache Hugo modules + uses: actions/cache@v4 + with: + path: /root/.cache/hugo + key: ${{ runner.os }}-hugo-${{ hashFiles('**/go.mod', '**/go.sum') }} + restore-keys: ${{ runner.os }}-hugo- - - name: Archive artifact - shell: sh + - name: Tidy & (optionally) vendor modules run: | - echo ::group::Archive artifact - tar \ - --dereference --hard-dereference \ - --directory "public" \ - -cvf "$RUNNER_TEMP/artifact.tar" \ - --exclude=.git \ - --exclude=.github \ - . - echo ::endgroup:: - - uses: actions/upload-artifact@v4 + hugo mod tidy + # hugo mod vendor # uncomment if you vendor modules + + - name: Build site + run: hugo --gc --minify + + - name: Upload Pages artifact + uses: actions/upload-pages-artifact@v3 with: - name: github-pages - path: ${{ runner.temp }}/artifact.tar - retention-days: 1 - if-no-files-found: error + path: ./public - publish: + deploy: needs: build runs-on: ubuntu-latest - permissions: - pages: write - id-token: write environment: name: github-pages url: ${{ steps.deployment.outputs.page_url }} steps: - - name: Deploy to GitHub Pages - uses: actions/deploy-pages@v4 - with: - token: ${{ secrets.GITHUB_TOKEN }} + - id: deployment + uses: actions/deploy-pages@v4 \ No newline at end of file diff --git a/Dockerfile b/Dockerfile index cf3f643..2b47afb 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,10 +1,8 @@ FROM floryn90/hugo:ext-alpine -# Ensure we are root while installing system packages so apk can lock/update its DB USER root RUN apk add --no-cache git && \ - git config --global --add safe.directory /src + git config --global --add safe.directory /src -# (Optional) drop back to a non-root user if the base image expects one. -# You can uncomment and adjust the USER line below if you know the non-root username. -# USER hugo +WORKDIR /src +CMD ["hugo", "server", "--bind", "0.0.0.0", "-D", "--ignoreCache"] diff --git a/docker-compose.yaml b/docker-compose.yaml index 7af155a..bae7f54 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -1,11 +1,12 @@ +version: "3.8" services: - - site: - image: eclipse-edc/eclipse-edc.github.io + web: build: context: . - command: server - ports: - - "1313:1313" + dockerfile: Dockerfile volumes: - .:/src + ports: + - "1313:1313" + environment: + HUGO_CACHEDIR: /tmp/hugo-cache diff --git a/docsy.work b/docsy.work deleted file mode 100644 index 074dc2a..0000000 --- a/docsy.work +++ /dev/null @@ -1,5 +0,0 @@ -go 1.19 - -use . -use ../docsy/ // Local docsy clone resides in sibling folder to this project -// use ./themes/docsy/ // Local docsy clone resides in themes folder diff --git a/docsy.work.sum b/docsy.work.sum deleted file mode 100644 index e69de29..0000000 diff --git a/go.mod b/go.mod index 00890a6..98f3725 100644 --- a/go.mod +++ b/go.mod @@ -1,5 +1,7 @@ -module github.com/google/docsy-example +module github.com/eclipse-edc/eclipse-edc.github.io + go 1.22 -go 1.12 + require ( + github.com/google/docsy v0.12.0 + ) -require github.com/google/docsy v0.10.0 // indirect diff --git a/package.json b/package.json index 152cd0c..3676f21 100644 --- a/package.json +++ b/package.json @@ -1,42 +1,9 @@ { - "name": "docsy-example-site", - "version": "0.10.0", - "version.next": "0.10.1-dev.0-unreleased", - "description": "Example site that uses Docsy theme for technical documentation.", - "repository": "github:google/docsy-example", - "homepage": "https://example.docsy.dev", - "author": "Docsy Authors", - "license": "Apache-2.0", - "bugs": "https://github.com/google/docsy-example/issues", - "spelling": "cSpell:ignore HTMLTEST precheck postbuild -", + "name": "eclipse-edc-website", + "version": "0.14.0", + "private": true, + "description": "Eclipse EDC website built with Hugo and Docsy, deployed via Docker and GitHub Pages.", "scripts": { - "_build": "npm run _hugo-dev --", - "_check:links": "echo IMPLEMENTATION PENDING for check-links; echo", - "_hugo": "hugo --cleanDestinationDir", - "_hugo-dev": "npm run _hugo -- -e dev -DFE", - "_local": "npx cross-env HUGO_MODULE_WORKSPACE=docsy.work", - "_serve": "npm run _hugo-dev -- --minify serve", - "build:preview": "npm run _hugo-dev -- --minify --baseURL \"${DEPLOY_PRIME_URL:-/}\"", - "build:production": "npm run _hugo -- --minify", - "build": "npm run _build -- ", - "check:links:all": "HTMLTEST_ARGS= npm run _check:links", - "check:links": "npm run _check:links", - "clean": "rm -Rf public/* resources", - "local": "npm run _local -- npm run", - "make:public": "git init -b main public", - "precheck:links:all": "npm run build", - "precheck:links": "npm run build", - "postbuild:preview": "npm run _check:links", - "postbuild:production": "npm run _check:links", - "serve": "npm run _serve", - "test": "npm run check:links", - "update:pkg:dep": "npm install --save-dev autoprefixer@latest postcss-cli@latest", - "update:pkg:hugo": "npm install --save-dev --save-exact hugo-extended@latest" - }, - "devDependencies": { - "autoprefixer": "^10.4.14", - "cross-env": "^10.0.0", - "hugo-extended": "0.152.2", - "postcss-cli": "^11.0.0" + "dev": "docker compose up" } } From 3f976146b7adbdad0da953fae2509cb82ad1018b Mon Sep 17 00:00:00 2001 From: Markus Spiekermann Date: Thu, 30 Oct 2025 09:46:51 +0000 Subject: [PATCH 03/23] remove netlify references --- netlify.toml | 12 ------------ 1 file changed, 12 deletions(-) delete mode 100644 netlify.toml diff --git a/netlify.toml b/netlify.toml deleted file mode 100644 index 7898ef8..0000000 --- a/netlify.toml +++ /dev/null @@ -1,12 +0,0 @@ -# Hugo build configuration for Netlify -# (https://gohugo.io/hosting-and-deployment/hosting-on-netlify/#configure-hugo-version-in-netlify) - -[build] -command = "npm run build:preview" -publish = "public" - -[build.environment] -GO_VERSION = "1.22.2" - -[context.production] -command = "npm run build:production" From 0cce9f35ed1ae0160546f67621d9519d6b5a2a76 Mon Sep 17 00:00:00 2001 From: Markus Spiekermann Date: Thu, 30 Oct 2025 10:01:10 +0000 Subject: [PATCH 04/23] update go.mod and go.sum --- go.sum | 8 ++++---- layouts/_default/_markup/render-heading.html | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/go.sum b/go.sum index 78bc934..3ed3add 100644 --- a/go.sum +++ b/go.sum @@ -1,4 +1,4 @@ -github.com/FortAwesome/Font-Awesome v0.0.0-20240402185447-c0f460dca7f7/go.mod h1:IUgezN/MFpCDIlFezw3L8j83oeiIuYoj28Miwr/KUYo= -github.com/google/docsy v0.10.0 h1:6tMDacPwAyRWNCfvsn/9qGOZDQ8b0aRzjRZvnZPY5dg= -github.com/google/docsy v0.10.0/go.mod h1:c0nIAqmRTOuJ01F85U/wJPQtc3Zj9N58Kea9bOT2AJc= -github.com/twbs/bootstrap v5.3.3+incompatible/go.mod h1:fZTSrkpSf0/HkL0IIJzvVspTt1r9zuf7XlZau8kpcY0= +github.com/FortAwesome/Font-Awesome v0.0.0-20241216213156-af620534bfc3/go.mod h1:IUgezN/MFpCDIlFezw3L8j83oeiIuYoj28Miwr/KUYo= +github.com/google/docsy v0.12.0 h1:CddZKL39YyJzawr8GTVaakvcUTCJRAAYdz7W0qfZ2P4= +github.com/google/docsy v0.12.0/go.mod h1:1bioDqA493neyFesaTvQ9reV0V2vYy+xUAnlnz7+miM= +github.com/twbs/bootstrap v5.3.6+incompatible/go.mod h1:fZTSrkpSf0/HkL0IIJzvVspTt1r9zuf7XlZau8kpcY0= diff --git a/layouts/_default/_markup/render-heading.html b/layouts/_default/_markup/render-heading.html index 7f8e974..0a34d42 100644 --- a/layouts/_default/_markup/render-heading.html +++ b/layouts/_default/_markup/render-heading.html @@ -1 +1 @@ -{{ template "_default/_markup/td-render-heading.html" . }} +{{- partial "td/render-heading.html" . -}} From 628086d7c3b9f77fa096eeacb2f707143cf82eb1 Mon Sep 17 00:00:00 2001 From: Markus Spiekermann Date: Thu, 30 Oct 2025 10:49:52 +0000 Subject: [PATCH 05/23] update GH Action --- .github/workflows/publish.yml | 29 ++++++++++++++++------------- Dockerfile | 2 +- 2 files changed, 17 insertions(+), 14 deletions(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 607a14d..879f602 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -1,8 +1,10 @@ -name: Build & Deploy (Docker) +name: Build & Deploy on: push: branches: [ main ] + pull_request: + branches: [ main ] workflow_dispatch: permissions: @@ -11,22 +13,26 @@ permissions: id-token: write concurrency: - group: pages + group: github-pages cancel-in-progress: true jobs: build: runs-on: ubuntu-latest - container: floryn90/hugo:0.124.0-ext-alpine + # Run all steps inside the Hugo + Node container + container: + image: floryn90/hugo:ext-alpine steps: - - uses: actions/checkout@v4 + - name: Checkout + uses: actions/checkout@v4 - - name: Install PostCSS deps (inside container) + # Git is needed for Hugo Modules resolution + - name: Install git run: | - apk add --no-cache nodejs npm git - npm install -g postcss postcss-cli autoprefixer - git config --global --add safe.directory $GITHUB_WORKSPACE + apk add --no-cache git + git config --global --add safe.directory "$GITHUB_WORKSPACE" + # Cache Hugo's module/remote cache (no vendoring) - name: Cache Hugo modules uses: actions/cache@v4 with: @@ -34,11 +40,6 @@ jobs: key: ${{ runner.os }}-hugo-${{ hashFiles('**/go.mod', '**/go.sum') }} restore-keys: ${{ runner.os }}-hugo- - - name: Tidy & (optionally) vendor modules - run: | - hugo mod tidy - # hugo mod vendor # uncomment if you vendor modules - - name: Build site run: hugo --gc --minify @@ -48,6 +49,8 @@ jobs: path: ./public deploy: + # Deploy only for main branch pushes (skip PRs) + if: github.event_name != 'pull_request' needs: build runs-on: ubuntu-latest environment: diff --git a/Dockerfile b/Dockerfile index 2b47afb..30f78f7 100644 --- a/Dockerfile +++ b/Dockerfile @@ -5,4 +5,4 @@ RUN apk add --no-cache git && \ git config --global --add safe.directory /src WORKDIR /src -CMD ["hugo", "server", "--bind", "0.0.0.0", "-D", "--ignoreCache"] +CMD ["server", "--bind", "0.0.0.0", "-D", "--ignoreCache"] From 77ee5de42a3f1264d149990a86b418de0157bbe3 Mon Sep 17 00:00:00 2001 From: Markus Spiekermann Date: Thu, 30 Oct 2025 11:00:24 +0000 Subject: [PATCH 06/23] update GH Action --- .github/workflows/publish.yml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 879f602..c9499bd 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -26,13 +26,18 @@ jobs: - name: Checkout uses: actions/checkout@v4 + # Computes the correct base URL + - name: Configure Pages + id: pages + uses: actions/configure-pages@v5 + # Git is needed for Hugo Modules resolution - name: Install git run: | apk add --no-cache git git config --global --add safe.directory "$GITHUB_WORKSPACE" - # Cache Hugo's module/remote cache (no vendoring) + # Cache Hugo's module/remote cache - name: Cache Hugo modules uses: actions/cache@v4 with: From c71d124a937c5458c16e620d50c7eff10d5c6e75 Mon Sep 17 00:00:00 2001 From: Markus Spiekermann Date: Thu, 30 Oct 2025 11:06:19 +0000 Subject: [PATCH 07/23] add missing user option in GH Action --- .github/workflows/publish.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index c9499bd..0f465f0 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -22,6 +22,7 @@ jobs: # Run all steps inside the Hugo + Node container container: image: floryn90/hugo:ext-alpine + options: --user 0 steps: - name: Checkout uses: actions/checkout@v4 From 34f5abe6dbf44477d087fe43194c378d17411808 Mon Sep 17 00:00:00 2001 From: Markus Spiekermann Date: Thu, 30 Oct 2025 11:19:56 +0000 Subject: [PATCH 08/23] install tar through docker as required by GH Action --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 30f78f7..90da098 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,7 +1,7 @@ FROM floryn90/hugo:ext-alpine USER root -RUN apk add --no-cache git && \ +RUN apk add --no-cache git tar && \ git config --global --add safe.directory /src WORKDIR /src From e8c3ae509583c3bd937e8017bb26a494854a29b4 Mon Sep 17 00:00:00 2001 From: Markus Spiekermann Date: Thu, 30 Oct 2025 11:23:51 +0000 Subject: [PATCH 09/23] update GH workflow to add tar --- .github/workflows/publish.yml | 2 +- Dockerfile | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 0f465f0..0e527bd 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -35,7 +35,7 @@ jobs: # Git is needed for Hugo Modules resolution - name: Install git run: | - apk add --no-cache git + apk add --no-cache git tar git config --global --add safe.directory "$GITHUB_WORKSPACE" # Cache Hugo's module/remote cache diff --git a/Dockerfile b/Dockerfile index 90da098..30f78f7 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,7 +1,7 @@ FROM floryn90/hugo:ext-alpine USER root -RUN apk add --no-cache git tar && \ +RUN apk add --no-cache git && \ git config --global --add safe.directory /src WORKDIR /src From e3ab9c0f027bdd69d7100d533d1e32db6deddc5c Mon Sep 17 00:00:00 2001 From: Markus Spiekermann Date: Thu, 30 Oct 2025 12:38:14 +0000 Subject: [PATCH 10/23] add postcss in workflow --- .github/workflows/publish.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 0e527bd..40f62d0 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -35,7 +35,8 @@ jobs: # Git is needed for Hugo Modules resolution - name: Install git run: | - apk add --no-cache git tar + apk add --no-cache git tar nodejs npm + npm i -g postcss postcss-cli autoprefixer git config --global --add safe.directory "$GITHUB_WORKSPACE" # Cache Hugo's module/remote cache From f44645949b3a010617ca974d5b0f407b0b27b704 Mon Sep 17 00:00:00 2001 From: Markus Spiekermann Date: Thu, 30 Oct 2025 12:44:56 +0000 Subject: [PATCH 11/23] add postcss in workflow --- .github/workflows/publish.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 40f62d0..c5ece18 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -36,8 +36,8 @@ jobs: - name: Install git run: | apk add --no-cache git tar nodejs npm - npm i -g postcss postcss-cli autoprefixer git config --global --add safe.directory "$GITHUB_WORKSPACE" + run: npm i -D postcss postcss-cli autoprefixer # Cache Hugo's module/remote cache - name: Cache Hugo modules From 7aa213ec0bc3141465962a4e6660390d4ea4b75c Mon Sep 17 00:00:00 2001 From: Markus Spiekermann Date: Thu, 30 Oct 2025 12:56:30 +0000 Subject: [PATCH 12/23] check canonifyURLs = true --- hugo.toml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hugo.toml b/hugo.toml index 73b6f8d..17eb7c8 100644 --- a/hugo.toml +++ b/hugo.toml @@ -1,4 +1,6 @@ baseURL = "https://eclipse-edc.github.io/" +# Ensures Hugo rewrites URLs using your baseURL +canonifyURLs = true title = "EDC" # Language settings From 31a5b0b5dd722a52bfa309a7ab0687bd9e9047ba Mon Sep 17 00:00:00 2001 From: Markus Spiekermann Date: Thu, 30 Oct 2025 12:58:05 +0000 Subject: [PATCH 13/23] rm double run in workflow --- .github/workflows/publish.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index c5ece18..392e101 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -36,8 +36,8 @@ jobs: - name: Install git run: | apk add --no-cache git tar nodejs npm + npm i -D postcss postcss-cli autoprefixer git config --global --add safe.directory "$GITHUB_WORKSPACE" - run: npm i -D postcss postcss-cli autoprefixer # Cache Hugo's module/remote cache - name: Cache Hugo modules From c00908d52b8b670f615bd57fbc9d1063764f8ab2 Mon Sep 17 00:00:00 2001 From: Markus Spiekermann Date: Thu, 30 Oct 2025 13:27:50 +0000 Subject: [PATCH 14/23] add baseURL in workflow --- .github/workflows/publish.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 392e101..f0f8ee4 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -48,7 +48,7 @@ jobs: restore-keys: ${{ runner.os }}-hugo- - name: Build site - run: hugo --gc --minify + run: hugo --gc --minify "${{ steps.pages.outputs.base_url }}" - name: Upload Pages artifact uses: actions/upload-pages-artifact@v3 From c07a348cd1dd6c4b22bad2b942a59b1c56af94fa Mon Sep 17 00:00:00 2001 From: Markus Spiekermann Date: Thu, 30 Oct 2025 13:30:11 +0000 Subject: [PATCH 15/23] add baseURL in workflow --- .github/workflows/publish.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index f0f8ee4..85ee88f 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -48,7 +48,7 @@ jobs: restore-keys: ${{ runner.os }}-hugo- - name: Build site - run: hugo --gc --minify "${{ steps.pages.outputs.base_url }}" + run: hugo --gc --minify --baseURL "${{ steps.pages.outputs.base_url }}" - name: Upload Pages artifact uses: actions/upload-pages-artifact@v3 From 889cbd39bb066a7d96da34538bcefccba007bf0f Mon Sep 17 00:00:00 2001 From: Markus Spiekermann Date: Thu, 30 Oct 2025 13:37:44 +0000 Subject: [PATCH 16/23] change fix URL in hugo.toml --- hugo.toml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hugo.toml b/hugo.toml index 17eb7c8..d701d94 100644 --- a/hugo.toml +++ b/hugo.toml @@ -1,5 +1,5 @@ -baseURL = "https://eclipse-edc.github.io/" -# Ensures Hugo rewrites URLs using your baseURL +# Basic page settings +baseURL = "https://mspiekermann.github.io/eclipse-edc.github.io/" canonifyURLs = true title = "EDC" From b566046b76ec6462dfa38c088e79233ae8087559 Mon Sep 17 00:00:00 2001 From: Markus Spiekermann Date: Thu, 30 Oct 2025 14:01:30 +0000 Subject: [PATCH 17/23] fix workflow for flexible repos --- .github/workflows/publish.yml | 4 +++- hugo.toml | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 85ee88f..e0afc1e 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -48,7 +48,9 @@ jobs: restore-keys: ${{ runner.os }}-hugo- - name: Build site - run: hugo --gc --minify --baseURL "${{ steps.pages.outputs.base_url }}" + env: + HUGO_BASEURL: ${{ steps.pages.outputs.base_url }} + run: hugo --gc --minify - name: Upload Pages artifact uses: actions/upload-pages-artifact@v3 diff --git a/hugo.toml b/hugo.toml index d701d94..96ad831 100644 --- a/hugo.toml +++ b/hugo.toml @@ -1,5 +1,5 @@ # Basic page settings -baseURL = "https://mspiekermann.github.io/eclipse-edc.github.io/" +baseURL = "https://eclipse-edc.github.io/" canonifyURLs = true title = "EDC" From 069bd5cef51f3b7a775d38bf18ddcc6ffda93e5d Mon Sep 17 00:00:00 2001 From: Markus Spiekermann Date: Thu, 30 Oct 2025 14:12:04 +0000 Subject: [PATCH 18/23] chores: revert workflow name --- .github/workflows/publish.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index e0afc1e..c9c79cd 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -1,4 +1,4 @@ -name: Build & Deploy +name: publish on: push: From ae2588e0e5fb7d051a7d88325b282bb03c7852e9 Mon Sep 17 00:00:00 2001 From: Markus Spiekermann Date: Fri, 31 Oct 2025 07:00:12 +0000 Subject: [PATCH 19/23] rm unnecessary scripts attribute in package.json --- package.json | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/package.json b/package.json index 3676f21..2bcb4c5 100644 --- a/package.json +++ b/package.json @@ -2,8 +2,5 @@ "name": "eclipse-edc-website", "version": "0.14.0", "private": true, - "description": "Eclipse EDC website built with Hugo and Docsy, deployed via Docker and GitHub Pages.", - "scripts": { - "dev": "docker compose up" - } + "description": "Eclipse EDC website built with Hugo and Docsy, deployed via Docker and GitHub Pages." } From bf067b69018cb13844c25122b81fa3f4367fc310 Mon Sep 17 00:00:00 2001 From: Markus Spiekermann Date: Fri, 31 Oct 2025 11:07:43 +0000 Subject: [PATCH 20/23] fix: incorporate feedback docker compose and gomod --- docker-compose.yaml | 2 -- go.mod | 8 ++++---- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/docker-compose.yaml b/docker-compose.yaml index bae7f54..7126f8f 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -1,9 +1,7 @@ -version: "3.8" services: web: build: context: . - dockerfile: Dockerfile volumes: - .:/src ports: diff --git a/go.mod b/go.mod index 98f3725..9650a8f 100644 --- a/go.mod +++ b/go.mod @@ -1,7 +1,7 @@ module github.com/eclipse-edc/eclipse-edc.github.io - go 1.22 +go 1.22 - require ( - github.com/google/docsy v0.12.0 - ) +require ( + github.com/google/docsy v0.12.0 +) From a7fc085ace4e9131a487c852c595d45d5714f0c2 Mon Sep 17 00:00:00 2001 From: Markus Spiekermann Date: Fri, 31 Oct 2025 12:12:55 +0000 Subject: [PATCH 21/23] rm install git in Dockerfile --- Dockerfile | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index 30f78f7..badc348 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,8 +1,7 @@ FROM floryn90/hugo:ext-alpine USER root -RUN apk add --no-cache git && \ - git config --global --add safe.directory /src +RUN git config --global --add safe.directory /src WORKDIR /src -CMD ["server", "--bind", "0.0.0.0", "-D", "--ignoreCache"] +CMD ["server", "--bind", "0.0.0.0", "-D", "--ignoreCache"] \ No newline at end of file From 7ca01e7e93453f4240695a7a2c76ec7cfce574b7 Mon Sep 17 00:00:00 2001 From: Markus Spiekermann Date: Fri, 31 Oct 2025 12:23:52 +0000 Subject: [PATCH 22/23] clean workflow on dependencies install --- .github/workflows/publish.yml | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index c9c79cd..a3d4b5d 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -32,11 +32,9 @@ jobs: id: pages uses: actions/configure-pages@v5 - # Git is needed for Hugo Modules resolution - - name: Install git - run: | - apk add --no-cache git tar nodejs npm - npm i -D postcss postcss-cli autoprefixer + # BusyBox tar in Alpine doesn't support --hard-dereference; install GNU tar + - name: Install tar + run: apk add --no-cache tar git config --global --add safe.directory "$GITHUB_WORKSPACE" # Cache Hugo's module/remote cache From e7aa47e9768e1dcbeca39653a05706b55b3e8fe7 Mon Sep 17 00:00:00 2001 From: Markus Spiekermann Date: Fri, 31 Oct 2025 12:27:03 +0000 Subject: [PATCH 23/23] fix literal block in workflow file --- .github/workflows/publish.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index a3d4b5d..bc97aa5 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -34,7 +34,8 @@ jobs: # BusyBox tar in Alpine doesn't support --hard-dereference; install GNU tar - name: Install tar - run: apk add --no-cache tar + run: | + apk add --no-cache tar git config --global --add safe.directory "$GITHUB_WORKSPACE" # Cache Hugo's module/remote cache