mprove warning/verbose messages around namespace in Fission CLI (#2572)
Removed extra warning message while creating HTTP trigger, and updated some verbose logs to show info related to the namespace.
This commit is contained in:
@@ -43,7 +43,7 @@ func (opts *DeleteSubCommand) do(input cli.Input) (err error) {
|
||||
if err != nil {
|
||||
return errors.Wrap(err, "error creating environment")
|
||||
}
|
||||
console.Verbose(2, "Namespace used to delete resource: %s ", currentContextNS)
|
||||
console.Verbose(2, "Searching for resource in %s Namespace", currentContextNS)
|
||||
|
||||
m := &metav1.ObjectMeta{
|
||||
Name: input.String(flagkey.EnvName),
|
||||
|
||||
@@ -126,8 +126,6 @@ func (opts *CreateSubCommand) complete(input cli.Input) error {
|
||||
Namespace: userProvidedNS,
|
||||
}
|
||||
|
||||
console.Warn(fmt.Sprintf("Ns: %v", userProvidedNS))
|
||||
|
||||
// For Specs, the spec validate checks for function reference
|
||||
if input.Bool(flagkey.SpecSave) {
|
||||
|
||||
|
||||
@@ -494,9 +494,9 @@ func GetResourceNamespace(input cli.Input, deprecatedFlag string) (namespace, cu
|
||||
if input.String(flagkey.Namespace) != "" {
|
||||
namespace = input.String(flagkey.Namespace)
|
||||
currentNS = namespace
|
||||
console.Verbose(2, "Namespace for resource %s ", currentNS)
|
||||
return namespace, currentNS, err
|
||||
}
|
||||
console.Verbose(2, "Namespace from user %s ", namespace)
|
||||
|
||||
if namespace == "" {
|
||||
if os.Getenv("FISSION_DEFAULT_NAMESPACE") != "" {
|
||||
@@ -513,7 +513,7 @@ func GetResourceNamespace(input cli.Input, deprecatedFlag string) (namespace, cu
|
||||
}
|
||||
}
|
||||
|
||||
console.Verbose(2, "Namespace final %s ", currentNS)
|
||||
console.Verbose(2, "Namespace for resource %s ", currentNS)
|
||||
|
||||
return namespace, currentNS, nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user