11 Commits

Author SHA1 Message Date
Alex Shevchuk
0fabd2aea3 67
All checks were successful
Deploy Production / Deploy to Staging (push) Has been skipped
Go Linter / Build golang services (api_gateway) (push) Has been skipped
Go Linter / Tag Commit (push) Successful in 6s
Go Linter / Run golangci-lint (api_gateway) (push) Has been skipped
Go Linter / Push Docker Images (api_gateway) (push) Has been skipped
2025-09-12 18:15:07 +03:00
Alex Shevchuk
e777399e72 66
All checks were successful
Deploy Production / Deploy to Staging (push) Has been skipped
Go Linter / Build golang services (api_gateway) (push) Has been skipped
Go Linter / Push Docker Images (api_gateway) (push) Has been skipped
Go Linter / Run golangci-lint (api_gateway) (push) Has been skipped
Go Linter / Tag Commit (push) Successful in 5s
2025-09-12 18:13:56 +03:00
Alex Shevchuk
66101c80c9 66
All checks were successful
Go Linter / Run golangci-lint (api_gateway) (push) Has been skipped
Deploy Production / Deploy to Staging (push) Has been skipped
Go Linter / Build golang services (api_gateway) (push) Has been skipped
Go Linter / Push Docker Images (api_gateway) (push) Has been skipped
Go Linter / Tag Commit (push) Successful in 6s
2025-09-12 18:12:17 +03:00
Alex Shevchuk
43bc32c77b 65
Some checks failed
Go Linter / Run golangci-lint (api_gateway) (push) Has been skipped
Deploy Production / Deploy to Staging (push) Has been skipped
Go Linter / Build golang services (api_gateway) (push) Has been skipped
Go Linter / Push Docker Images (api_gateway) (push) Has been skipped
Go Linter / Tag Commit (push) Failing after 6s
2025-09-12 18:05:32 +03:00
Alex Shevchuk
d3cfa1cbcf 65
Some checks failed
Deploy Production / Deploy to Staging (push) Has been skipped
Go Linter / Build golang services (api_gateway) (push) Has been skipped
Go Linter / Run golangci-lint (api_gateway) (push) Has been skipped
Go Linter / Push Docker Images (api_gateway) (push) Has been skipped
Go Linter / Tag Commit (push) Failing after 5s
2025-09-08 15:19:19 +03:00
Alex Shevchuk
dc5a26c146 65
Some checks failed
Go Linter / Run golangci-lint (api_gateway) (push) Has been skipped
Deploy Production / Deploy to Staging (push) Has been skipped
Go Linter / Build golang services (api_gateway) (push) Has been skipped
Go Linter / Push Docker Images (api_gateway) (push) Has been skipped
Go Linter / Tag Commit (push) Failing after 6s
2025-09-08 15:16:53 +03:00
Alex Shevchuk
0acef09910 64
All checks were successful
Deploy Production / Deploy to Staging (push) Has been skipped
Go Linter / Run golangci-lint (api_gateway) (push) Has been skipped
Go Linter / Push Docker Images (api_gateway) (push) Has been skipped
Go Linter / Build golang services (api_gateway) (push) Has been skipped
Go Linter / Tag Commit (push) Successful in 7s
2025-09-08 15:13:54 +03:00
Alex Shevchuk
24fb916074 63
All checks were successful
Go Linter / Run golangci-lint (api_gateway) (push) Has been skipped
Go Linter / Push Docker Images (api_gateway) (push) Has been skipped
Go Linter / Tag Commit (push) Successful in 6s
Deploy Production / Deploy to Staging (push) Has been skipped
Go Linter / Build golang services (api_gateway) (push) Has been skipped
2025-09-08 14:55:08 +03:00
Alex Shevchuk
5aaadf4fe6 63
Some checks failed
Go Linter / Run golangci-lint (api_gateway) (push) Has been skipped
Deploy Production / Deploy to Staging (push) Has been skipped
Go Linter / Build golang services (api_gateway) (push) Has been skipped
Go Linter / Push Docker Images (api_gateway) (push) Has been skipped
Go Linter / Tag Commit (push) Failing after 5s
2025-09-08 14:53:44 +03:00
Alex Shevchuk
30a5e8340e 63
All checks were successful
Deploy Production / Deploy to Staging (push) Has been skipped
2025-09-08 14:53:13 +03:00
Alex Shevchuk
42ea0f58fd 62
Some checks failed
Deploy Production / Deploy to Staging (push) Has been skipped
Go Linter / Build golang services (api_gateway) (push) Has been cancelled
Go Linter / Push Docker Images (api_gateway) (push) Has been cancelled
Go Linter / Run golangci-lint (api_gateway) (push) Has been cancelled
Go Linter / Tag Commit (push) Failing after 6s
2025-09-08 14:46:35 +03:00
2 changed files with 29 additions and 10 deletions

View File

@@ -5,17 +5,14 @@ on:
branches:
- master
- release
tags:
- '*'
push:
branches:
- master
- release
tags:
- '*'
jobs:
lint:
if: 0
name: Run golangci-lint
runs-on: ubuntu-22.04
@@ -43,6 +40,7 @@ jobs:
golangci-lint run -c ./.golangci-lint.yaml --fix=false --color=always
build:
if: 0
name: Build golang services
runs-on: ubuntu-22.04
needs: lint
@@ -67,10 +65,11 @@ jobs:
CGO_ENABLED=0 GOOS=linux go build -ldflags="-s -w" -o main cmd/main.go
push:
if: 0
name: Push Docker Images
runs-on: ubuntu-22.04
needs: lint
if: ${{ gitea.ref == 'refs/heads/master' || gitea.ref == 'refs/heads/release' }}
# if: ${{ gitea.ref == 'refs/heads/master' || gitea.ref == 'refs/heads/release' }}
strategy:
matrix:
@@ -140,6 +139,9 @@ jobs:
tag:
name: Tag Commit
runs-on: ubuntu-22.04
rules:
- if: github.event_name == 'push' && github.ref_type == 'tag'
when: never
# needs: lint
steps:
@@ -151,8 +153,10 @@ jobs:
- name: Get latest tag
id: get-latest-tag
run: |
git fetch --tags
git fetch --tags --force
LATEST_TAG=$(git describe --tags --abbrev=0 2>/dev/null || echo 'v0.0.0')
echo $LATEST_TAG
if [[ $LATEST_TAG =~ ^v([0-9]+)\.([0-9]+)\.([0-9]+)$ ]]; then
MAJOR=${BASH_REMATCH[1]}
@@ -164,12 +168,28 @@ jobs:
PATCH=0
fi
echo $MAJOR.$MINOR.$PATCH
NEW_PATCH=$((PATCH + 1))
NEW_TAG="v${MAJOR}.${MINOR}.${NEW_PATCH}"
echo "NEW_TAG=${NEW_TAG}" >> $GITHUB_OUTPUT
echo "NEW_TAG=$NEW_TAG" >> $GITHUB_OUTPUT
- name: Push tag
if git ls-remote --tags origin "refs/tags/$NEW_TAG" | grep -q "$NEW_TAG"; then
echo "Tag $NEW_TAG already exists remotely, skipping tag creation"
echo "TAG_EXISTS=true" >> $GITHUB_OUTPUT
else
echo "TAG_EXISTS=false" >> $GITHUB_OUTPUT
fi
- name: Push tag (if it doesn't exist)
if: steps.get-latest-tag.outputs.TAG_EXISTS == 'false'
run: |
git tag ${{ steps.get-latest-tag.outputs.NEW_TAG }}
git push origin ${{ steps.get-latest-tag.outputs.NEW_TAG }}
echo "Successfully pushed tag: ${{ steps.get-latest-tag.outputs.NEW_TAG }}"
- name: Skip tag push (tag already exists)
if: steps.get-latest-tag.outputs.TAG_EXISTS == 'true'
run: |
echo "Skipping tag push - tag ${{ steps.get-latest-tag.outputs.NEW_TAG }} already exists remotely"

View File

@@ -167,4 +167,3 @@ molva-backend/
- `commit` - хеш коммита
- `date` - дата сборки