-
Notifications
You must be signed in to change notification settings - Fork 23.7k
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
--start-at-task only respected for first batch of serial #82150
Comments
Files identified in the description: None If these files are incorrect, please update the |
@sivel , any pointers to how I might help fix this? |
At this point I would deprecate and remove the feature and implement actual breakpoints. fixing it requires redesigning the feature to account for batching/serial as task names are not unique and the way it is cleared right now is required to actually be able to move on after the specified task. |
Is --start-at-task deprecated? What is the appropriate way to start at a task? |
It is not deprecated, I'm just saying that could be an option going forward, that user expectations have gone far from what it does and how it was designed and that we might require scraping the current feature in favor of something that is more robust, complete and can actually meet this type of usage |
But you suggested implementing breakpoints, which is not what I really wanted using this. I wanted the run to skip a few steps and start from a certain task. How would we achieve this with breakpoints? |
The breakpoints themselves would not do it, but make it possible to implement set a breakpoint, run play 'skipping up to X breakpoint' or 'run to X breakpoint and start -steps', etc , they would also not require 'clearing' as there would not be any possible duplication (like with task name), so they can apply per batch, which is your use case. But the feature goes well beyond just this specific case, this was just the 'latest' in a series of requests that convinced me we do actually need this in the engine. |
Oh, OK OK. I think I understand now, thanks for clarifying. Is there a proposal for breakpoints already that I can look at? I would like to help with whatever is need to achieve a behavior like what you described. |
its coalescing in my head, I posted here to make sure i follow up, mostly creating the breakpoints themselves should be pretty simple, a hidden task attribute, declaring them for a run and handling them will require fixes to the base strategy class, play iterator and task execution ... that requires more thinking/time. |
Do tags not help you here? You can use skip tags or run tags to choose which parts to run. |
It could help! I will check it out. Still |
Summary
When I set serial, it correctly starts at the task passed in the flag, but for the second batch it ignores it and starts from the beggining of the playbook.
Issue Type
Bug Report
Component Name
playbook
Ansible Version
Configuration
OS / Environment
macbook M2 13.2.1 (22D68)
❯ uname -a
Darwin ... 22.3.0 Darwin Kernel Version 22.3.0: Mon Jan 30 20:38:43 PST 2023; root:xnu-8792.81.3~2/RELEASE_ARM64_T8112 arm64
Steps to Reproduce
playbook
❯ ansible-playbook -i inventory.yaml --start-at-task second
Expected Results
Actual Results
Code of Conduct
The text was updated successfully, but these errors were encountered: