You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
Several commands support the namespace flag and also the ability to specify the namespace through the manifest and we have different behaviors depending on the command.
When I execute okteto deploy -n ifbyol, the dev environment (empty) is deployed within new-ifbyol but the hello deployment is deployed within ifbyol namespace
When I execute okteto destroy -n ifbyol, I get an error The namespace in the okteto manifest doesn't match your namespace argument
Also, from a coding perspective, sometimes we are setting the Namespace specified in the options struct we usually create with the flags with the context namespace if the user didn't specify one and in other commands we are not doing that and create other struct with the real values for the command
Describe the solution you'd like
An homogeneous behavior of the Namespace flag. If the specified flag cannot be different to the one specified in the manifest, the deploy operation should fail as the destroy does.
Ideally, we should also follow the same convention when defined flags for the commands and then, how they are passed to the real command execution. We should probably decouple both and have an struct with all the specified flags for the user and then, have another different with the real values that will be used by the command (so the one specified by the user would override the default values without modifying any original value)
We should also review the behavior of the namespace flag in other commands to make sure it behaves correctly and we don't have this issue
Describe alternatives you've considered
N/A
Additional context
I think this would help to make things less error-prone
The text was updated successfully, but these errors were encountered:
Is your feature request related to a problem? Please describe.
Several commands support the namespace flag and also the ability to specify the namespace through the manifest and we have different behaviors depending on the command.
For example, using the repository https://github.com/jmacelroy/go-getting-started.git, if I include a
namespace
property in theokteto.yml
with the namespacenew-ifbyol
okteto deploy -n ifbyol
, the dev environment (empty) is deployed withinnew-ifbyol
but thehello
deployment is deployed withinifbyol
namespaceokteto destroy -n ifbyol
, I get an errorThe namespace in the okteto manifest doesn't match your namespace argument
Also, from a coding perspective, sometimes we are setting the Namespace specified in the
options
struct we usually create with the flags with the context namespace if the user didn't specify one and in other commands we are not doing that and create other struct with the real values for the commandDescribe the solution you'd like
An homogeneous behavior of the Namespace flag. If the specified flag cannot be different to the one specified in the manifest, the deploy operation should fail as the destroy does.
Ideally, we should also follow the same convention when defined flags for the commands and then, how they are passed to the real command execution. We should probably decouple both and have an struct with all the specified flags for the user and then, have another different with the real values that will be used by the command (so the one specified by the user would override the default values without modifying any original value)
We should also review the behavior of the namespace flag in other commands to make sure it behaves correctly and we don't have this issue
Describe alternatives you've considered
N/A
Additional context
I think this would help to make things less error-prone
The text was updated successfully, but these errors were encountered: