Skip to content

Commit

Permalink
fix: Wrong condition
Browse files Browse the repository at this point in the history
  • Loading branch information
ilyakuz-db committed Nov 18, 2024
1 parent 49f6bc9 commit e65b50c
Showing 1 changed file with 6 additions and 7 deletions.
13 changes: 6 additions & 7 deletions bundle/config/mutator/process_target_mode.go
Original file line number Diff line number Diff line change
Expand Up @@ -59,19 +59,18 @@ func transformDevelopmentMode(ctx context.Context, b *bundle.Bundle) {
}

if !config.IsExplicitlyDisabled(t.InPlaceDeployment) {
enabled := true
t.InPlaceDeployment = &enabled
}

if !config.IsExplicitlyDisabled(t.PipelinesDevelopment) {
root := b.SyncRootPath
isInWorkspace := strings.HasPrefix(root, "/Workspace/")

if isInWorkspace && dbr.RunsOnRuntime(ctx) {
enabled := true
t.PipelinesDevelopment = &enabled
t.InPlaceDeployment = &enabled
}
}

if !config.IsExplicitlyDisabled(t.PipelinesDevelopment) {
enabled := true
t.PipelinesDevelopment = &enabled
}
}

func validateDevelopmentMode(b *bundle.Bundle) diag.Diagnostics {
Expand Down

0 comments on commit e65b50c

Please sign in to comment.