Skip to content

Commit

Permalink
fix(pulumi): respect --skip-dependencies flag in pulumi preview c…
Browse files Browse the repository at this point in the history
…ommand

The flag was implemented in #3096.
The logic that respects the flag was removed in e54d1b5,
likely by accident.
This commit restores the logic that prevents dependency resolution if the corresponding flag is set.
  • Loading branch information
vvagaytsev committed Jun 25, 2024
1 parent b71f3c7 commit c546a22
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions plugins/pulumi/src/commands.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ import {
import { dedent, deline } from "@garden-io/sdk/build/src/util/string.js"
import { BooleanParameter, parsePluginCommandArgs } from "@garden-io/sdk/build/src/util/cli.js"
import fsExtra from "fs-extra"

const { copy, emptyDir } = fsExtra
import { join } from "path"
import { isDeployAction } from "@garden-io/core/build/src/actions/deploy.js"
Expand Down Expand Up @@ -271,6 +272,10 @@ class PulumiPluginCommandTask extends PluginActionTask<PulumiDeploy, PulumiComma
* Override the base method to be sure that `garden plugins pulumi preview` happens in dependency order.
*/
override resolveProcessDependencies() {
if (this.skipRuntimeDependencies) {
return []
}

const pulumiDeployNames = this.graph
.getDeploys()
.filter((d) => d.type === "pulumi")
Expand Down

0 comments on commit c546a22

Please sign in to comment.