Switched to net9 and finished event workflow

This commit is contained in:
2026-01-18 19:30:20 +01:00
parent 8d0573eb7e
commit 2d3c973d47
23 changed files with 142 additions and 40 deletions

41
.gitlab-ci.yml Normal file
View File

@@ -0,0 +1,41 @@
stages:
- build
- test
- publish
variables:
DOCKER_IMAGE: registry.leon-hoppe.de/leon.hoppe/spotiparty
build:
stage: build
image: mcr.microsoft.com/dotnet/sdk:9.0
script:
- dotnet restore
- dotnet build --configuration Release --no-restore
artifacts:
paths:
- "**/bin/Release"
expire_in: 10 minutes
test:
stage: test
image: mcr.microsoft.com/dotnet/sdk:9.0
script:
- dotnet test --verbosity normal
dependencies:
- build
publish:
stage: publish
tags:
- docker
before_script:
- git lfs pull
script:
- export VERSION=$(echo $CI_COMMIT_TAG | sed 's/^v//')
- echo "$CI_REGISTRY_PASSWORD" | docker login -u "$CI_REGISTRY_USER" --password-stdin registry.leon-hoppe.de
- docker build -t $DOCKER_IMAGE:$VERSION -t $DOCKER_IMAGE:latest -f SpotiParty.Web/Dockerfile .
- docker push $DOCKER_IMAGE:$VERSION
- docker push $DOCKER_IMAGE:latest
only:
- tags