Skip to content

Commit cab0d54

Browse files
committed
don't abort if ALB values can't be read
1 parent c96948c commit cab0d54

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

cmd/cli/multiregion/dns.go

+4-2
Original file line numberDiff line numberDiff line change
@@ -192,12 +192,14 @@ func (d *DnsCommand) getAlbDnsValuesFromTfc(workspaceName string) (values AlbDns
192192

193193
w, err := client.Workspaces.Read(ctx, d.tfcOrg, workspaceName)
194194
if err != nil {
195-
log.Fatalf("Error reading Terraform workspace %s: %s", workspaceName, err)
195+
fmt.Printf("Error reading Terraform workspace %s: %s", workspaceName, err)
196+
return
196197
}
197198

198199
outputs, err := client.StateVersionOutputs.ReadCurrent(ctx, w.ID)
199200
if err != nil {
200-
log.Fatalf("Error reading Terraform state outputs on workspace %s: %s", workspaceName, err)
201+
fmt.Printf("Error reading Terraform state outputs on workspace %s: %s", workspaceName, err)
202+
return
201203
}
202204

203205
for _, item := range outputs.Items {

0 commit comments

Comments
 (0)