Skip to content

Database governance built for humans and agents — controlling changes and access across every major database.

fix: use gitops URL for gitops ci (#6780)

Danny Xu65a23934f6d7
diff --git a/.github/workflows/backend-tests.yml b/.github/workflows/backend-tests.yml
index f5881681cf..30b306ff01 100644
--- a/.github/workflows/backend-tests.yml
+++ b/.github/workflows/backend-tests.yml
@@ -11,6 +11,7 @@ on:
jobs:
golangci-lint:
runs-on: ubuntu-latest
+ timeout-minutes: 20
steps:
- name: Checkout
uses: actions/checkout@v3
@@ -38,7 +39,7 @@ jobs:
uses: golangci/golangci-lint-action@v3
with:
version: v1.52.2
- args: --verbose --timeout 10m --max-same-issues=30
+ args: --verbose --timeout 20m --max-same-issues=30
skip-cache: true
go-tests:
diff --git a/.golangci.yaml b/.golangci.yaml
index 4118eff5a0..48f84ff6da 100644
--- a/.golangci.yaml
+++ b/.golangci.yaml
@@ -34,7 +34,7 @@ issues:
- Exit(.*)_(.*)
run:
- timeout: 5m
+ timeout: 20m
build-tags:
- mysql
skip-dirs:
diff --git a/backend/api/v1/project_service.go b/backend/api/v1/project_service.go
index 367124c24f..463f62103e 100644
--- a/backend/api/v1/project_service.go
+++ b/backend/api/v1/project_service.go
@@ -980,7 +980,11 @@ func (s *ProjectService) setupVCSSQLReviewCI(ctx context.Context, repository *st
return nil, err
}
- sqlReviewEndpoint := fmt.Sprintf("%s/hook/sql-review/%s", setting.ExternalUrl, repository.WebhookEndpointID)
+ endpoint := setting.ExternalUrl
+ if setting.GitopsWebhookUrl != "" {
+ endpoint = setting.GitopsWebhookUrl
+ }
+ sqlReviewEndpoint := fmt.Sprintf("%s/hook/sql-review/%s", endpoint, repository.WebhookEndpointID)
switch vcs.Type {
case vcsPlugin.GitHub: