Skip to content

Commit 813738b

Browse files
Merge branch 'develop' into config-diff-3-oss
2 parents 43c779a + 73ad83e commit 813738b

File tree

3 files changed

+6
-2
lines changed

3 files changed

+6
-2
lines changed

internal/sql/repository/pipelineConfig/CdWorfkflowRepository.go

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -693,9 +693,10 @@ func (impl *CdWorkflowRepositoryImpl) GetLatestTriggersOfHelmPipelinesStuckInNon
693693
Where("cd_workflow_runner.cd_workflow_id in"+
694694
" (SELECT max(cd_workflow.id) as id from cd_workflow"+
695695
" INNER JOIN cd_workflow_runner on cd_workflow.id = cd_workflow_runner.cd_workflow_id"+
696-
" WHERE cd_workflow_runner.status != ?"+
696+
" WHERE cd_workflow_runner.workflow_type = ? "+
697+
" AND cd_workflow_runner.status != ?"+
697698
" GROUP BY cd_workflow.pipeline_id"+
698-
" ORDER BY cd_workflow.pipeline_id desc)", cdWorkflow.WorkflowInQueue).
699+
" ORDER BY cd_workflow.pipeline_id desc)", apiBean.CD_WORKFLOW_TYPE_DEPLOY, cdWorkflow.WorkflowInQueue).
699700
Where("(cd_workflow__pipeline.deployment_app_type=? or dc.deployment_app_type=?)", util.PIPELINE_DEPLOYMENT_TYPE_HELM, util.PIPELINE_DEPLOYMENT_TYPE_HELM).
700701
Where("cd_workflow_runner.started_on > NOW() - INTERVAL '? hours'", getPipelineDeployedWithinHours).
701702
Where("cd_workflow__pipeline.deleted=?", false).

scripts/casbin/10_terminal.down.sql

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
DELETE FROM casbin_rule where v0='role:super-admin___' and v1='terminal';

scripts/casbin/10_terminal.up.sql

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
INSERT INTO "public"."casbin_rule" ("p_type", "v0", "v1", "v2", "v3", "v4", "v5") VALUES
2+
('p','role:super-admin___','terminal','*','*','allow','');

0 commit comments

Comments
 (0)