-
Notifications
You must be signed in to change notification settings - Fork 17
Open
Labels
MIGRATED-MIGRATEDMigrated to private repoMigrated to private repoenhancementNew feature or requestNew feature or requestneeds-triage
Description
Description of problem
workload create/apply supports setting a handful of string-based workload object values via flags.
Once any of those flag/values have been set, the only way to unset them today is to pass a --file workload.yaml with those properties/values removed and use --update-strategy replace.
For someone who prefers to manage/configure their workload via apps commands/flags or someone unfamiliar with the workload object and/or yaml, this is inconvenient toil.
Proposed solution
Enable unsetting of string-based flags by passing an empty string.
Given I've created a workload via command such as `tanzu apps workload create my-app --git-repo github.com/foo/bar --git-branch main --limit-cpu 500m`
When I run an update command such as `tanzu apps workload create my-app --git-repo github.com/foo/bar --git-branch main --limit-cpu ""`
Then limit-cpu and it's value are unset in my workloadGiven I'm looking at the output for `tanzu apps workload create/apply --help`
When I view any help line for a flag in the list of flags to be updated as per this issue
Then I see `(to unset, pass empty string "")` appended to the flag descriptionList of flags to update
- --app
- --image (not sure if this one belongs in the list - let's discuss)
- --limit-cpu
- --limit-memory
- --maven-type
- --request-cpu
- --request-memory
And these already have this feature enabled:
- --service-account
- --sub-path
- --git*
Metadata
Metadata
Assignees
Labels
MIGRATED-MIGRATEDMigrated to private repoMigrated to private repoenhancementNew feature or requestNew feature or requestneeds-triage