5 Commits

Author SHA1 Message Date
596baba5ef added permissions for packages and moved token to actions checkout
All checks were successful
Gitea CI/CD / Set Tag Name (push) Successful in 5s
Gitea CI/CD / build-and-test (push) Successful in 44s
Gitea CI/CD / docker-build-and-push (push) Successful in 5m39s
Gitea CI/CD / Create Tag (push) Successful in 5s
2025-10-04 01:41:06 +02:00
12390031f9 added permissions to write
All checks were successful
Gitea CI/CD / Set Tag Name (push) Successful in 5s
Gitea CI/CD / build-and-test (push) Successful in 52s
Gitea CI/CD / docker-build-and-push (push) Successful in 7m29s
Gitea CI/CD / Create Tag (push) Successful in 7s
2025-10-04 01:15:16 +02:00
daed8c1462 .gitea/workflows/build.yaml aktualisiert
Some checks failed
Gitea CI/CD / Set Tag Name (push) Successful in 5s
Gitea CI/CD / docker-build-and-push (push) Has been cancelled
Gitea CI/CD / Create Tag (push) Has been cancelled
Gitea CI/CD / build-and-test (push) Has been cancelled
2025-10-04 00:52:35 +02:00
7e5e295590 .gitea/workflows/build.yaml aktualisiert
Some checks failed
Gitea CI/CD / Set Tag Name (push) Successful in 6s
Gitea CI/CD / build-and-test (push) Successful in 51s
Gitea CI/CD / Create Tag (push) Has been cancelled
Gitea CI/CD / docker-build-and-push (push) Has been cancelled
2025-10-04 00:34:47 +02:00
cb91ca3159 .gitea/workflows/build.yaml aktualisiert
All checks were successful
Gitea CI/CD / build-and-test (push) Successful in 1m5s
Gitea CI/CD / Set Tag Name (push) Successful in 7s
Gitea CI/CD / docker-build-and-push (push) Successful in 5m56s
Gitea CI/CD / Create Tag (push) Successful in 5s
2025-10-04 00:20:55 +02:00

View File

@@ -5,21 +5,22 @@ on:
push: push:
branches: [ "development", "main", "staging"] branches: [ "development", "main", "staging"]
tags: [ "v*.*.*" ] tags: [ "v*.*.*" ]
pull_request: #pull_request:
branches: [ "development", "main", "staging" ] #branches: [ "development", "main", "staging" ]
permissions:
contents: write
packages: write
env: env:
DOTNET_VERSION: '8.0.x' DOTNET_VERSION: '8.0.x'
DOCKER_IMAGE_NAME: watcher-server DOCKER_IMAGE_NAME: watcher-server
REGISTRY_URL: git.triggermeelmo.com REGISTRY_URL: git.triggermeelmo.com
DOCKER_PLATFORMS: 'linux/amd64,linux/arm64' DOCKER_PLATFORMS: 'linux/amd64,linux/arm64'
TAG: ${{ github.ref == 'refs/heads/main' && 'latest' || github.ref == 'refs/heads/development' && 'development' || github.ref_type == 'tag' && github.ref_name || 'pr' }}
jobs: jobs:
build-and-test: build-and-test:
runs-on: ubuntu-latest runs-on: ubuntu-latest
env:
RUNNER_TOOL_CACHE: /toolcache # Runner Tool Cache
steps: steps:
- name: Checkout code - name: Checkout code
uses: actions/checkout@v4 uses: actions/checkout@v4
@@ -45,8 +46,6 @@ jobs:
set-tag: set-tag:
name: Set Tag Name name: Set Tag Name
runs-on: ubuntu-latest runs-on: ubuntu-latest
env:
RUNNER_TOOL_CACHE: /toolcache
outputs: outputs:
tag_name: ${{ steps.set_tag.outputs.tag_name }} tag_name: ${{ steps.set_tag.outputs.tag_name }}
steps: steps:
@@ -75,7 +74,7 @@ jobs:
elif [[ "${GITHUB_REF}" == "refs/heads/development" ]]; then elif [[ "${GITHUB_REF}" == "refs/heads/development" ]]; then
minor=$((minor + 1)) minor=$((minor + 1))
patch=0 patch=0
else elif [[ "${GITHUB_REF}" == "refs/heads/staging" ]]; then
patch=$((patch + 1)) patch=$((patch + 1))
fi fi
@@ -84,8 +83,6 @@ jobs:
docker-build-and-push: docker-build-and-push:
runs-on: ubuntu-latest runs-on: ubuntu-latest
env:
RUNNER_TOOL_CACHE: /toolcache # Runner Tool Cache
needs: [build-and-test, set-tag] needs: [build-and-test, set-tag]
steps: steps:
- name: Checkout code - name: Checkout code
@@ -112,12 +109,11 @@ jobs:
name: Create Tag name: Create Tag
needs: [docker-build-and-push] needs: [docker-build-and-push]
runs-on: ubuntu-latest runs-on: ubuntu-latest
env:
RUNNER_TOOL_CACHE: /toolcache
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
with: with:
fetch-depth: 0 fetch-depth: 0
token: ${{ secrets.GITHUB_TOKEN }}
- name: Set up Git user - name: Set up Git user
run: | run: |
@@ -125,8 +121,6 @@ jobs:
git config user.email "actions@github.com" git config user.email "actions@github.com"
- name: Create and push tag - name: Create and push tag
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: | run: |
git tag ${{ needs.set-tag.outputs.tag_name }} git tag ${{ needs.set-tag.outputs.tag_name }}
git push origin ${{ needs.set-tag.outputs.tag_name }} git push origin ${{ needs.set-tag.outputs.tag_name }}