Consume podspec patch directly on executor/builder mounts (#2661)

Signed-off-by: Sanket Sudake <sanketsudake@gmail.com>

Signed-off-by: Sanket Sudake <sanketsudake@gmail.com>
This commit is contained in:
Sanket Sudake
2022-12-08 11:38:57 +05:30
committed by GitHub
parent 4dde3c9520
commit 985d94b5b8
12 changed files with 79 additions and 105 deletions
-11
View File
@@ -216,17 +216,6 @@ func IsZip(filename string) (bool, error) {
return archiver.DefaultZip.Match(f)
}
// GetCurrentNamespace returns Kubernetes namespace of current Pod
func GetCurrentNamespace() (string, error) {
// This file contains the namespace and can be found in each container.
body, err := os.ReadFile("/var/run/secrets/kubernetes.io/serviceaccount/namespace")
if err != nil {
return "", err
}
return string(body), nil
}
func GetStringValueFromEnv(envVar string) (string, error) {
v := os.Getenv(envVar)
if v == "" {