Skip to content

Commit

Permalink
fix to not check workspaceId for a VR (#857)
Browse files Browse the repository at this point in the history
* fix to not check workspaceId for a VR

* Trigger Build
  • Loading branch information
kushalmalani committed Nov 3, 2022
1 parent a7c9f44 commit 6aea0ac
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
3 changes: 2 additions & 1 deletion cmd/cloud/deploy.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ package cloud

import (
"fmt"
"strings"

cloud "github.com/astronomer/astro-cli/cloud/deploy"
"github.com/astronomer/astro-cli/cmd/utils"
Expand Down Expand Up @@ -92,7 +93,7 @@ func deploy(cmd *cobra.Command, args []string) error {
deploymentID = args[0]
}

if deploymentID == "" || forcePrompt || workspaceID == "" {
if (!strings.HasPrefix(deploymentID, "vr-")) && (deploymentID == "" || forcePrompt || workspaceID == "") {
var err error
workspaceID, err = coalesceWorkspace()
if err != nil {
Expand Down
3 changes: 3 additions & 0 deletions cmd/cloud/deploy_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -57,4 +57,7 @@ func TestDeployImage(t *testing.T) {

err = execDeployCmd([]string{"-f", "test-deployment-id", "--dags", "--parse", "--pytest"}...)
assert.NoError(t, err)

err = execDeployCmd([]string{"vr-Id"}...)
assert.NoError(t, err)
}

0 comments on commit 6aea0ac

Please sign in to comment.