Simplify workflows: drop setup-node/pnpm-action, use corepack
Some checks failed
CI / changes (push) Successful in 1s
CI / lint-and-test (push) Successful in 32s
Deploy Production / deploy (push) Failing after 19s
CI / build (push) Has been skipped

The runner containers use node:20-bookworm which already has Node
and corepack. Remove actions/setup-node and pnpm/action-setup
which hang in Gitea Actions. Use corepack enable + pnpm directly.
Also fix preview comment to use Gitea API instead of github-script.
This commit is contained in:
Julia McGhee
2026-03-21 16:31:01 +00:00
parent b28b1fcae2
commit 0b69d6c6f4
3 changed files with 12 additions and 38 deletions

View File

@@ -10,12 +10,7 @@ jobs:
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v4
- uses: actions/setup-node@v4
with:
node-version: 20
cache: pnpm
- run: corepack enable && corepack prepare pnpm@latest --activate
- run: pnpm install --frozen-lockfile
@@ -48,17 +43,11 @@ jobs:
done
- name: Comment preview URL
uses: actions/github-script@v7
with:
script: |
const { owner, repo } = context.repo;
const issue_number = context.issue.number;
const body = `## Preview Deploy\nNamespace: \`preview-${issue_number}\`\nArgoCD will sync automatically from branch \`${context.payload.pull_request.head.ref}\`.`;
await fetch(`${process.env.GITHUB_API_URL}/repos/${owner}/${repo}/issues/${issue_number}/comments`, {
method: 'POST',
headers: {
'Authorization': `token ${process.env.GITHUB_TOKEN}`,
'Content-Type': 'application/json'
},
body: JSON.stringify({ body })
});
env:
GITEA_TOKEN: ${{ gitea.token }}
run: |
curl -s -X POST \
-H "Authorization: token ${GITEA_TOKEN}" \
-H "Content-Type: application/json" \
-d "{\"body\": \"## Preview Deploy\nNamespace: \`preview-${{ gitea.event.number }}\`\nArgoCD will sync automatically.\"}" \
"${{ gitea.server_url }}/api/v1/repos/${{ gitea.repository }}/issues/${{ gitea.event.number }}/comments"