From 9aa00d45b6c3e12377ecfb9a61c7a530f0941caa Mon Sep 17 00:00:00 2001 From: Benjamin Sago Date: Wed, 12 Sep 2018 17:55:02 +0100 Subject: [PATCH] Exit with error code 1 when failing to list DCs (#4583) Fixes #4582. --- command/catalog/list/dc/catalog_list_datacenters.go | 1 + 1 file changed, 1 insertion(+) diff --git a/command/catalog/list/dc/catalog_list_datacenters.go b/command/catalog/list/dc/catalog_list_datacenters.go index f9b923ad8..3ab152538 100644 --- a/command/catalog/list/dc/catalog_list_datacenters.go +++ b/command/catalog/list/dc/catalog_list_datacenters.go @@ -49,6 +49,7 @@ func (c *cmd) Run(args []string) int { dcs, err := client.Catalog().Datacenters() if err != nil { c.UI.Error(fmt.Sprintf("Error listing datacenters: %s", err)) + return 1 } for _, dc := range dcs {