summaryrefslogtreecommitdiffstats
path: root/src/k8splugin/internal
diff options
context:
space:
mode:
Diffstat (limited to 'src/k8splugin/internal')
-rw-r--r--src/k8splugin/internal/app/client.go3
-rw-r--r--src/k8splugin/internal/utils.go4
2 files changed, 2 insertions, 5 deletions
diff --git a/src/k8splugin/internal/app/client.go b/src/k8splugin/internal/app/client.go
index 8d2af297..d44f3505 100644
--- a/src/k8splugin/internal/app/client.go
+++ b/src/k8splugin/internal/app/client.go
@@ -122,8 +122,6 @@ func (k *KubernetesClient) ensureNamespace(namespace string) error {
func (k *KubernetesClient) createKind(resTempl helm.KubernetesResourceTemplate,
namespace string) (helm.KubernetesResource, error) {
- log.Println("Processing Kind: " + resTempl.GVK.Kind)
-
if _, err := os.Stat(resTempl.FilePath); os.IsNotExist(err) {
return helm.KubernetesResource{}, pkgerrors.New("File " + resTempl.FilePath + "does not exists")
}
@@ -137,6 +135,7 @@ func (k *KubernetesClient) createKind(resTempl helm.KubernetesResourceTemplate,
createdResourceName, err := pluginImpl.Create(resTempl.FilePath, namespace, k)
if err != nil {
+ log.Printf("Error: %s while creating: %s", err.Error(), resTempl.GVK.Kind)
return helm.KubernetesResource{}, pkgerrors.Wrap(err, "Error in plugin "+resTempl.GVK.Kind+" plugin")
}
diff --git a/src/k8splugin/internal/utils.go b/src/k8splugin/internal/utils.go
index 47a236c2..174f8e79 100644
--- a/src/k8splugin/internal/utils.go
+++ b/src/k8splugin/internal/utils.go
@@ -17,8 +17,8 @@ import (
"io/ioutil"
"log"
"os"
- "path/filepath"
"path"
+ "path/filepath"
"plugin"
"strings"
@@ -52,13 +52,11 @@ func DecodeYAML(path string, into runtime.Object) (runtime.Object, error) {
}
}
- log.Println("Reading YAML file")
rawBytes, err := ioutil.ReadFile(path)
if err != nil {
return nil, pkgerrors.Wrap(err, "Read YAML file error")
}
- log.Println("Decoding deployment YAML")
decode := scheme.Codecs.UniversalDeserializer().Decode
obj, _, err := decode(rawBytes, nil, into)
if err != nil {