Harden Gitea CI resource usage
CI - Build & Verify / Build, Typecheck & Hygiene (push) Failing after 12s
CI - Build & Verify / Build, Typecheck & Hygiene (push) Failing after 12s
This commit is contained in:
+22
-41
@@ -12,47 +12,10 @@ on:
|
|||||||
branches: [main]
|
branches: [main]
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
backend:
|
verify:
|
||||||
name: Backend (.NET)
|
name: Build, Typecheck & Hygiene
|
||||||
runs-on: linux
|
runs-on: ubuntu-latest
|
||||||
steps:
|
timeout-minutes: 20
|
||||||
- name: Checkout
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
|
|
||||||
- name: Setup .NET SDK
|
|
||||||
uses: actions/setup-dotnet@v4
|
|
||||||
with:
|
|
||||||
dotnet-version: '8.0.x'
|
|
||||||
|
|
||||||
- name: Restore
|
|
||||||
run: dotnet restore Backend/Backend.csproj
|
|
||||||
|
|
||||||
- name: Build
|
|
||||||
run: dotnet build Backend/Backend.csproj --no-restore --configuration Release
|
|
||||||
|
|
||||||
frontend:
|
|
||||||
name: Frontend (Vue/TS)
|
|
||||||
runs-on: linux
|
|
||||||
steps:
|
|
||||||
- name: Checkout
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
|
|
||||||
- name: Setup Node.js
|
|
||||||
uses: actions/setup-node@v4
|
|
||||||
with:
|
|
||||||
node-version: '24'
|
|
||||||
|
|
||||||
- name: Install dependencies
|
|
||||||
run: npm ci
|
|
||||||
working-directory: frontend
|
|
||||||
|
|
||||||
- name: Build
|
|
||||||
run: npm run build
|
|
||||||
working-directory: frontend
|
|
||||||
|
|
||||||
hygiene:
|
|
||||||
name: Repository Hygiene
|
|
||||||
runs-on: linux
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
@@ -82,3 +45,21 @@ jobs:
|
|||||||
echo "$hits"
|
echo "$hits"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
- name: Backend build
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
docker run --rm \
|
||||||
|
-v "${{ gitea.workspace }}:/workspace" \
|
||||||
|
-w /workspace \
|
||||||
|
mcr.microsoft.com/dotnet/sdk:8.0-alpine \
|
||||||
|
sh -lc 'dotnet restore Backend/Backend.csproj && dotnet build Backend/Backend.csproj --no-restore --configuration Release'
|
||||||
|
|
||||||
|
- name: Frontend build
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
docker run --rm \
|
||||||
|
-v "${{ gitea.workspace }}:/workspace" \
|
||||||
|
-w /workspace/frontend \
|
||||||
|
node:24-alpine \
|
||||||
|
sh -lc 'npm ci && npm run build'
|
||||||
|
|||||||
@@ -27,6 +27,7 @@ jobs:
|
|||||||
deploy:
|
deploy:
|
||||||
name: Deploy to award.noveria.net
|
name: Deploy to award.noveria.net
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
timeout-minutes: 30
|
||||||
if: |
|
if: |
|
||||||
github.event_name == 'workflow_dispatch' ||
|
github.event_name == 'workflow_dispatch' ||
|
||||||
(github.event_name == 'workflow_run' &&
|
(github.event_name == 'workflow_run' &&
|
||||||
|
|||||||
Reference in New Issue
Block a user