From 657855bd4183a04211827228eae9f3d8fa80d578 Mon Sep 17 00:00:00 2001 From: James Brechtel Date: Thu, 14 May 2026 15:50:09 -0400 Subject: [PATCH] Fix CI: remove Docker-in-Docker, install Stack directly The ./hs Docker wrapper runs docker inside the Gitea runner container. Since project paths inside the runner container don't exist on the Docker host, the volume mount creates an empty /work directory, and Stack finds no packages (error S-8506). Fix: install Stack directly via get.haskellstack.org, use STACK_ROOT for caching, and build with stack directly (no Docker-in-Docker). Also add symlink for gitea-actions.sh convenience script. --- .gitea/workflows/build.yml | 16 +++++++++------- scripts/gitea-actions.sh | 1 + 2 files changed, 10 insertions(+), 7 deletions(-) create mode 120000 scripts/gitea-actions.sh diff --git a/.gitea/workflows/build.yml b/.gitea/workflows/build.yml index 0cfbf1e..7095e94 100644 --- a/.gitea/workflows/build.yml +++ b/.gitea/workflows/build.yml @@ -9,24 +9,26 @@ jobs: build: runs-on: ubuntu-latest env: - CONVERGE_HASKELL_TOOLS_IMAGE: ghcr.io/flipstone/haskell-tools:debian-ghc-9.10.3-5d6640d + STACK_ROOT: .stack-root steps: - name: Checkout uses: actions/checkout@v4 - with: - path: . + + - name: Install Stack + run: | + curl -sSL https://get.haskellstack.org/ | sh - name: Cache Stack uses: actions/cache@v4 with: path: .stack-root - key: stack-${{ runner.os }}-${{ hashFiles('stack.yaml', 'package.yaml') }} - restore-keys: stack-${{ runner.os }}- + key: stack-v2-${{ runner.os }}-${{ hashFiles('stack.yaml', 'package.yaml') }} + restore-keys: stack-v2-${{ runner.os }}- - name: Build run: | - mkdir -p .stack-root build - ./hs stack build --copy-bins --local-bin-path /work/build + mkdir -p build + stack build --copy-bins --local-bin-path ./build - name: Compress with UPX run: | diff --git a/scripts/gitea-actions.sh b/scripts/gitea-actions.sh new file mode 120000 index 0000000..88efe37 --- /dev/null +++ b/scripts/gitea-actions.sh @@ -0,0 +1 @@ +../.pi/skills/gitea-actions/scripts/gitea-actions.sh \ No newline at end of file