Fix: move undeclared vars to preconditions in Taskfile.yaml for impro… #6501
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
As you know, our infrastructure is very similar, so it's been a little too convenient to leverage your hard work. As solid as your code is, unannounced and/or breaking changes come like Murphy's law! Your recent feature to support multiple clusters came right during a rebuild 😅
Although it is a minor contribution, at least it is something. Moving these undeclared vars into preconditions revealed what changed/broke right away. Hopefully it might help others not to spend countless hours spinning up containers to re-run those task files.
This pull request is a hotfix for the
.taskfiles
directory, specifically it provides higher reliability and an improved debugging experience with human readable error messages. Main task changes:.taskfiles/ExternalSecrets/Taskfile.yaml
: Removed thecluster
variable from theExternalSecrets
task and added a precondition to check if thecluster
argument is required. [1] [2].taskfiles/VolSync/Taskfile.yaml
: Removed thecluster
variable from theVolSync
task and added preconditions to check if thecluster
argument is required. [1] [2] [3] [4] [5].taskfiles/Flux/Taskfile.yaml
: Removed thecluster
variable from thevars
section of theFlux
task. [1] [2].taskfiles/Kubernetes/Taskfile.yaml
: Removed thecluster
variable from thevars
section of theKubernetes
task..taskfiles/Ansible/Taskfile.yaml
: Added preconditions to theAnsible
task to check if thecluster
andplaybook
arguments are required.