-
Notifications
You must be signed in to change notification settings - Fork 140
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
failure in k8s task when using a definition list should have better error message #28
Comments
cc @fabianvf |
@fabianvf my example might not be exactly what you are looking for (because it really isn't a list that my example pulls in). Feel free to change any of this to get this to what you want :) I think you understand what I was doing though - maybe this isn't exactly what you were thinking I was doing. |
@jmazzitelli I am not sure if we can tell which definition file failed since we are generating a "big" YAML file using jinja for loop. I don't have the background for your requirement but I think the helm chart is the way to go forward. Helm chart handles multiple resources. |
You are saying re-implement my entire operator (to use helm rather than ansible) to workaround this issue? That's obviously a no-go for me. @fabianvf thoughts? |
OK. Will wait for @fabianvf to comment. |
@Akasurde there shouldn't be any need for a helm chart here, there should be nothing you can do easily with helm that you can't easily do with pure Ansible (if there is we should address that gap). The |
Thanks @fabianvf. Any opinions on how to handle an error? Should the module stop processing once a resource operation fails or continue to try more? |
Can you make that configurable? |
@jmazzitelli I am working on this issue. |
this has been addressed in the following PR #49 |
SUMMARY
Use a list in k8s definition list:
If there is a syntax error in one of the templates (or simply that a resource in the list fails to be created), the error message that k8s spits out doesn't tell you WHICH item in the list fails.
ISSUE TYPE
COMPONENT NAME
k8s
ANSIBLE VERSION
2.9
STEPS TO REPRODUCE
See above.
EXPECTED RESULTS
An error message that better indicates which item in the list failed.
It might also be nice to have the rest of the items processed, but that might break the k8s design. As it is, if you have ANY error in ANY item in the list, the entire list of resources apparently fail to be persisted/created.
ACTUAL RESULTS
You do get an error, but all resources abort (fail to get created) so you aren't sure which item in the list caused the failure.
The text was updated successfully, but these errors were encountered: