Skip to content

Commit fcfa897

Browse files
iamayushmgireesh-naidukamal-devtronkirandevtnprakarsh-dt
authored
fix: Bulk deploy panic and docker tag handling (#5949)
* removing fetchArtifacts V1 usage and abstracting tag extraction logic * docker tag and repo method in util * modifying image tag logic in release override * wip: adding empty path check * review changes * fix: app update migration (#5903) * wip: adding app name check * wip * wip * wip * moving migration to code * wip: adding app name in log * wip: moving sql logic to code * pg no rows handling * adding db migration call * fixing fetch app query * wip: adding pg multiple rows handling * audit log update * fix: nil ptr fix in copying extraEnvVars * feat: Docker lint plugin (#5694) * added up script for docker linit plugin * rename of script file * docker lint down script * changes in docker lint * hadolint image * change in name of plugin * changes in down script * chnages in docker lint * chnages in down script * change in hadolint image * rename down script file * renaming sql script * feat: Added Devtron CI Trigger v1.1.0 (#5934) * Create 028901_019_devtron_ci_trigger_v1_1.down.sql * Create 028901_019_devtron_ci_trigger_v1_1.up.sql * Update 028901_019_devtron_ci_trigger_v1_1.up.sql --------- Co-authored-by: Prakarsh <[email protected]> * renaming docker lint script file (#5937) * fix: err handling for configmap access * release: PR for v0.7.3 (#5942) * Update Chart.yaml * Update devtron-bom.yaml * Update values.yaml * Update devtron-installer.yaml * Update installation-script * Update version.txt * Update devtron.yaml * Update releasenotes.md * Update devtron-bom.yaml * Update values.yaml * Update releasenotes.md * Update releasenotes.md * Updated release-notes files * Update releasenotes.md * Update release.txt * Updated release-notes files * Update release-notes-v0.7.2.md --------- Co-authored-by: ReleaseBot <[email protected]> * wip: modifying tags function * sync --------- Co-authored-by: Gireesh Naidu <[email protected]> Co-authored-by: Gireesh Naidu <[email protected]> Co-authored-by: kamal-devtron <[email protected]> Co-authored-by: Kiran <[email protected]> Co-authored-by: Prakarsh <[email protected]> Co-authored-by: Pawan Mehta <[email protected]> Co-authored-by: ReleaseBot <[email protected]>
1 parent f6092df commit fcfa897

35 files changed

+419
-386
lines changed

CHANGELOG/release-notes-v0.7.3.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
## v0.7.3
2+
3+
4+
5+
## Bugs
6+
- fix: Builds set to auto not getting triggered (#5925)
7+
- fix: User Rbac Fixes (#5940)

Wire.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,7 @@ import (
105105
security2 "github.com/devtron-labs/devtron/internal/sql/repository/security"
106106
"github.com/devtron-labs/devtron/internal/util"
107107
"github.com/devtron-labs/devtron/pkg/app"
108+
"github.com/devtron-labs/devtron/pkg/app/dbMigration"
108109
"github.com/devtron-labs/devtron/pkg/app/status"
109110
"github.com/devtron-labs/devtron/pkg/appClone"
110111
"github.com/devtron-labs/devtron/pkg/appClone/batch"
@@ -1005,6 +1006,9 @@ func InitializeApp() (*App, error) {
10051006

10061007
repocreds.NewServiceClientImpl,
10071008
wire.Bind(new(repocreds.ServiceClient), new(*repocreds.ServiceClientImpl)),
1009+
1010+
dbMigration.NewDbMigrationServiceImpl,
1011+
wire.Bind(new(dbMigration.DbMigration), new(*dbMigration.DbMigrationServiceImpl)),
10081012
)
10091013
return &App{}, nil
10101014
}

api/restHandler/app/pipeline/configure/DeploymentPipelineRestHandler.go

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1337,17 +1337,16 @@ func (handler *PipelineConfigRestHandlerImpl) GetArtifactsByCDPipeline(w http.Re
13371337
return
13381338
}
13391339
//rbac block ends here
1340-
var ciArtifactResponse *bean.CiArtifactResponse
1341-
if handler.pipelineRestHandlerEnvConfig.UseArtifactListApiV2 {
1342-
artifactsListFilterOptions := &bean2.ArtifactsListFilterOptions{
1343-
Limit: limit,
1344-
Offset: offset,
1345-
SearchString: searchString,
1346-
}
1347-
ciArtifactResponse, err = handler.pipelineBuilder.RetrieveArtifactsByCDPipelineV2(pipeline, bean2.WorkflowType(stage), artifactsListFilterOptions)
1348-
} else {
1349-
ciArtifactResponse, err = handler.pipelineBuilder.RetrieveArtifactsByCDPipeline(pipeline, bean2.WorkflowType(stage))
1340+
artifactsListFilterOptions := &bean2.ArtifactsListFilterOptions{
1341+
Limit: limit,
1342+
Offset: offset,
1343+
SearchString: searchString,
13501344
}
1345+
1346+
//RetrieveArtifactsByCDPipeline is deprecated and method is removed from code
1347+
//ciArtifactResponse, err = handler.pipelineBuilder.RetrieveArtifactsByCDPipeline(pipeline, bean2.WorkflowType(stage))
1348+
1349+
ciArtifactResponse, err := handler.pipelineBuilder.RetrieveArtifactsByCDPipelineV2(pipeline, bean2.WorkflowType(stage), artifactsListFilterOptions)
13511350
if err != nil {
13521351
handler.Logger.Errorw("service err, GetArtifactsByCDPipeline", "err", err, "cdPipelineId", cdPipelineId, "stage", stage)
13531352
common.WriteJsonResp(w, err, nil, http.StatusInternalServerError)

api/restHandler/app/pipeline/configure/PipelineConfigRestHandler.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ import (
6262
)
6363

6464
type PipelineRestHandlerEnvConfig struct {
65-
UseArtifactListApiV2 bool `env:"USE_ARTIFACT_LISTING_API_V2" envDefault:"true"`
65+
UseArtifactListApiV2 bool `env:"USE_ARTIFACT_LISTING_API_V2" envDefault:"true"` //deprecated
6666
}
6767

6868
type DevtronAppRestHandler interface {

assets/hadolint-icon.png

12.5 KB
Loading

charts/devtron/Chart.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
apiVersion: v2
22
name: devtron-operator
3-
appVersion: 0.7.2
3+
appVersion: 0.7.3
44
description: Chart to configure and install Devtron. Devtron is a Kubernetes Orchestration system.
55
keywords:
66
- Devtron
@@ -11,7 +11,7 @@ keywords:
1111
- argocd
1212
- Hyperion
1313
engine: gotpl
14-
version: 0.22.74
14+
version: 0.22.75
1515
sources:
1616
- https://github.com/devtron-labs/charts
1717
dependencies:

charts/devtron/devtron-bom.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ global:
1010
containerRegistry: "quay.io/devtron"
1111
extraManifests: []
1212
installer:
13-
release: "v0.7.2"
13+
release: "v0.7.3"
1414
registry: ""
1515
image: "inception"
1616
tag: "473deaa4-185-21582"
@@ -38,8 +38,8 @@ components:
3838
imagePullPolicy: IfNotPresent
3939
devtron:
4040
registry: ""
41-
image: "hyperion:3f68456b-280-25566"
42-
cicdImage: "devtron:3f68456b-434-25567"
41+
image: "hyperion:e17c52eb-280-25812"
42+
cicdImage: "devtron:e17c52eb-434-25813"
4343
imagePullPolicy: IfNotPresent
4444
customOverrides: {}
4545
ciRunner:

charts/devtron/values.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ global:
2424
extraManifests: []
2525
installer:
2626
repo: "devtron-labs/devtron"
27-
release: "v0.7.2"
27+
release: "v0.7.3"
2828
registry: ""
2929
image: inception
3030
tag: 473deaa4-185-21582
@@ -81,8 +81,8 @@ components:
8181
imagePullPolicy: IfNotPresent
8282
devtron:
8383
registry: ""
84-
image: "hyperion:3f68456b-280-25566"
85-
cicdImage: "devtron:3f68456b-434-25567"
84+
image: "hyperion:e17c52eb-280-25812"
85+
cicdImage: "devtron:e17c52eb-434-25813"
8686
imagePullPolicy: IfNotPresent
8787
customOverrides: {}
8888
serviceMonitor:

client/telemetry/TelemetryEventClient.go

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -601,6 +601,10 @@ func (impl *TelemetryEventClientImpl) SendTelemetryDashboardAccessEvent() error
601601
return err
602602
}
603603
cm, err := impl.K8sUtil.GetConfigMap(impl.aCDAuthConfig.ACDConfigMapNamespace, DevtronUniqueClientIdConfigMap, client)
604+
if err != nil {
605+
impl.logger.Errorw("DashboardAccessed EventForTelemetry,failed to get DevtronUniqueClientIdConfigMap", "error", err)
606+
return err
607+
}
604608
datamap := cm.Data
605609

606610
accessEventValue, installEventKeyExists := datamap[UIEventKey]
@@ -667,6 +671,10 @@ func (impl *TelemetryEventClientImpl) SendTelemetryDashboardLoggedInEvent() erro
667671
return err
668672
}
669673
cm, err := impl.K8sUtil.GetConfigMap(impl.aCDAuthConfig.ACDConfigMapNamespace, DevtronUniqueClientIdConfigMap, client)
674+
if err != nil {
675+
impl.logger.Errorw("DashboardLoggedIn EventForTelemetry,failed to get DevtronUniqueClientIdConfigMap", "error", err)
676+
return err
677+
}
670678
datamap := cm.Data
671679

672680
accessEventValue, installEventKeyExists := datamap[UIEventKey]

cmd/external-app/wire.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,7 @@ import (
6464
security2 "github.com/devtron-labs/devtron/internal/sql/repository/security"
6565
"github.com/devtron-labs/devtron/internal/util"
6666
"github.com/devtron-labs/devtron/pkg/app"
67+
"github.com/devtron-labs/devtron/pkg/app/dbMigration"
6768
repository4 "github.com/devtron-labs/devtron/pkg/appStore/chartGroup/repository"
6869
"github.com/devtron-labs/devtron/pkg/appStore/installedApp/service/EAMode"
6970
"github.com/devtron-labs/devtron/pkg/appStore/installedApp/service/FullMode/deployment"
@@ -253,6 +254,9 @@ func InitializeApp() (*App, error) {
253254

254255
argoRepositoryCreds.NewRepositorySecret,
255256
wire.Bind(new(argoRepositoryCreds.RepositorySecret), new(*argoRepositoryCreds.RepositorySecretImpl)),
257+
258+
dbMigration.NewDbMigrationServiceImpl,
259+
wire.Bind(new(dbMigration.DbMigration), new(*dbMigration.DbMigrationServiceImpl)),
256260
)
257261
return &App{}, nil
258262
}

0 commit comments

Comments
 (0)