starting apply message cleanup

This commit is contained in:
Shreyas Goenka 2023-04-19 16:02:30 +02:00
parent e0369512b4
commit 8da8dd579d
No known key found for this signature in database
GPG Key ID: 92A07DF49CCB0622
2 changed files with 7 additions and 4 deletions

View File

@ -72,9 +72,14 @@ func (w *apply) Apply(ctx context.Context, b *bundle.Bundle) ([]bundle.Mutator,
return nil, fmt.Errorf("no plan found")
}
cmdio.LogString(ctx, "\nStarting resource deployment")
if w.goal == ApplyDeploy {
cmdio.LogString(ctx, "\nStarting resource deployment")
}
if w.goal == ApplyDestroy {
cmdio.LogString(ctx, "\nStarting resource destruction")
}
// Apply terraform according to the computed destroy plan
// Apply terraform according to the computed plan
err = tf.Apply(ctx, tfexec.DirOrPlan(b.Plan.Path))
if err != nil {
return nil, fmt.Errorf("terraform apply: %w", err)

View File

@ -13,8 +13,6 @@ import (
"golang.org/x/term"
)
// TODO: note possibility of aliases
var destroyCmd = &cobra.Command{
Use: "destroy",
Short: "Destroy deployed bundle resources",