Add extra logging when getting stack by name

This commit is contained in:
Juan Carlos Mejías Rodríguez 2019-08-06 23:13:32 -04:00
parent b3f1989a25
commit ba9f9b8725
2 changed files with 6 additions and 1 deletions

View File

@ -44,7 +44,9 @@ var stackDeployCmd = &cobra.Command{
}
logrus.WithFields(logrus.Fields{
"stack": stackName,
"stack": stackName,
"endpoint": endpointId,
"swarm": endpointSwarmClusterId,
}).Debug("Getting stack")
retrievedStack, stackRetrievalErr := common.GetStackByName(stackName, endpointSwarmClusterId, endpointId)
switch stackRetrievalErr.(type) {

View File

@ -16,6 +16,9 @@ var stackRemoveCmd = &cobra.Command{
Args: cobra.ExactArgs(1),
Run: func(cmd *cobra.Command, args []string) {
stackName := args[0]
logrus.WithFields(logrus.Fields{
"stack": stackName,
}).Debug("Getting stack")
stack, err := common.GetStackByName(stackName, "", 0)
switch err.(type) {