Implemented actual tested RunEdgeApp and StopEdgeApp commands, added sleep time after container operation and before checking status

This commit is contained in:
Paulo Truta
2021-02-18 22:59:14 +00:00
parent 0bd61ccf75
commit 3cc670b823
3 changed files with 90 additions and 23 deletions
+3 -2
View File
@@ -4,6 +4,7 @@ import (
"bytes"
"log"
"os/exec"
"fmt"
"github.com/joho/godotenv"
)
@@ -18,10 +19,10 @@ func Exec(command string, args []string) string {
err := cmd.Run()
if err != nil {
// TODO: Deal with possibility of error in command, allow explicit error handling and return proper formatted stderr
// log.Println(fmt.Sprint(err) + ": " + stderr.String()) ... Silence...
log.Println(fmt.Sprint(err) + ": " + stderr.String()) // ... Silence...
}
// log.Println("Result: " + out.String()) ... Silence ...
log.Println("Result: " + out.String()) // ... Silence ...
return out.String()