Skip to content

Commit

Permalink
Merge branch 'master' into TT-11298
Browse files Browse the repository at this point in the history
  • Loading branch information
mativm02 committed Dec 18, 2024
2 parents 5ee8f57 + 9ba9f0b commit 0377996
Show file tree
Hide file tree
Showing 31 changed files with 983 additions and 1,733 deletions.
3 changes: 0 additions & 3 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -1,5 +1,2 @@
/ci/ @TykTechnologies/devops
.github/workflows/release.yml @TykTechnologies/devops
.github/workflows/sync-automation.yml @TykTechnologies/devops
.github/workflows/pac.yml @TykTechnologies/devops
/repo-policy/ @TykTechnologies/devops
2 changes: 0 additions & 2 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,6 @@ updates:
directory: "/"
schedule:
interval: "weekly"
reviewers:
- "TykTechnologies/devops"

- package-ecosystem: "gomod"
# Look for `go.mod` file in the `root` directory
Expand Down
105 changes: 52 additions & 53 deletions .github/workflows/ci-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@ on:
- release-**
env:
TYK_IB_STORAGE_STORAGETYPE: file

permissions:
contents: read

jobs:
golangci-lint:
runs-on: ubuntu-latest
Expand All @@ -32,15 +32,15 @@ jobs:
with:
version: latest
args: --out-format=checkstyle:golanglint.xml --timeout=600s --max-issues-per-linter=0 --max-same-issues=0 --new-from-rev=origin/${{ github.base_ref }}
- uses: actions/upload-artifact@v2
- uses: actions/upload-artifact@v3
with:
name: golangcilint
retention-days: 1
path: |
golanglint.xml
ci-test:
name: '${{ matrix.databases }}'
name: "${{ matrix.databases }}"
runs-on: ubuntu-latest
strategy:
fail-fast: false
Expand All @@ -52,41 +52,40 @@ jobs:
redis-version: [5]
mongodb-version: [4.2]
steps:
- name: Checkout Code
uses: actions/checkout@v4
with:
fetch-depth: 2

- name: Setup Go
uses: actions/setup-go@v2
with:
go-version: '^1.21'
- name: Checkout Code
uses: actions/checkout@v4
with:
fetch-depth: 2

- name: Setup Go
uses: actions/setup-go@v2
with:
go-version: "^1.21"

- name: Install Dependencies and basic hygiene test
id: hygiene
run: |
go install golang.org/x/tools/cmd/goimports@latest
- name: Install Dependencies and basic hygiene test
id: hygiene
run: |
go install golang.org/x/tools/cmd/goimports@latest
- name: Start Redis
uses: supercharge/[email protected]
with:
- name: Start Redis
uses: supercharge/[email protected]
with:
redis-version: ${{ matrix.redis-version }}

- name: Start MongoDB
uses: supercharge/[email protected]
with:
mongodb-version: '${{ matrix.mongodb-version }}'

- name: Run tests
run: |
./bin/ci-tests.sh ${{ matrix.databases }}
- uses: actions/upload-artifact@v2
with:
name: coverage
retention-days: 1
path: |
*cov
- name: Start MongoDB
uses: supercharge/[email protected]
with:
mongodb-version: "${{ matrix.mongodb-version }}"

- name: Run tests
run: |
./bin/ci-tests.sh ${{ matrix.databases }}
- uses: actions/upload-artifact@v3
with:
name: coverage
retention-days: 1
path: |
*cov
sonar-cloud-analysis:
runs-on: ubuntu-latest
needs: [ci-test, golangci-lint]
Expand All @@ -101,40 +100,40 @@ jobs:
- name: Setup Golang
uses: actions/setup-go@v3
with:
go-version: 1.21
go-version: 1.22.6
- name: Download coverage artifacts
uses: actions/download-artifact@v2
uses: actions/download-artifact@v3
with:
name: coverage
- name: Download golangcilint artifacts
uses: actions/download-artifact@v2
uses: actions/download-artifact@v3
with:
name: golangcilint
- name: Check reports existence
id: check_files
uses: andstor/file-existence-action@v1
with:
files: '*.cov, golanglint.xml'
files: "*.cov, golanglint.xml"
- name: Install Dependencies
run: >
go install github.com/wadey/gocovmerge@latest
- name: merge reports
run: |
./bin/merge-cov.sh
- name: SonarCloud Scan
uses: sonarsource/sonarcloud-github-action@master
with:
args: >
-Dsonar.organization=tyktechnologies
-Dsonar.projectKey=TykTechnologies_tyk-identity-broker
-Dsonar.sources=.
-Dsonar.exclusions=ci/**
-Dsonar.coverage.exclusions=**/*_test.go,**/mocks/*.go
-Dsonar.test.inclusions=**/*_test.go
-Dsonar.tests=.
-Dsonar.go.coverage.reportPaths=*.cov
-Dsonar.go.golangci-lint.reportPaths=golanglint.xml
args: >
-Dsonar.organization=tyktechnologies
-Dsonar.projectKey=TykTechnologies_tyk-identity-broker
-Dsonar.sources=.
-Dsonar.exclusions=ci/**
-Dsonar.coverage.exclusions=**/*_test.go,**/mocks/*.go
-Dsonar.test.inclusions=**/*_test.go
-Dsonar.tests=.
-Dsonar.go.coverage.reportPaths=*.cov
-Dsonar.go.golangci-lint.reportPaths=golanglint.xml
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
85 changes: 0 additions & 85 deletions .github/workflows/pac.yml

This file was deleted.

Loading

0 comments on commit 0377996

Please sign in to comment.