we are using ansible in order to install our application and configuration on linux machines
here is example of general.pb.yml
#-----------------------------------------------------------------------------
# java apps installtion
#-----------------------------------------------------------------------------
- import_playbook: /deployment/application/stage1.pb.yml
- import_playbook: /deployment/application/stage2.pb.yml
- import_playbook: /deployment/application/stage3.pb.yml
- import_playbook: /deployment/application/stage4.pb.yml
- import_playbook: /deployment/application/stage5.pb.yml
- import_playbook: /deployment/application/stage6.pb.yml
- import_playbook: /deployment/application/stage7.pb.yml
- import_playbook: /deployment/application/stage8.pb.yml
- import_playbook: /deployment/application/stage9.pb.yml
- import_playbook: /deployment/application/stage10.pb.yml
- import_playbook: /deployment/application/stage11.pb.yml
.
.
.
.
the thing is when we run pb.yml
again and again on 2 time or 3 time , its means ansible spending time on the tasks that already performed
I will give example
lets say we run ansible-playbook general.pb.yml
and we want to perform only the task – /deployment/application/stage8.pb.yml
that not performed correctly on previous time
in that case ansible will verify all stages from stage1.pb.yml
until stage7.pb.yml
, and will spend time like 10 min until ansible start with /deployment/application/stage8.pb.yml
what we did as worker around we comment the lines as following
#-----------------------------------------------------------------------------
# java apps installtion
#-----------------------------------------------------------------------------
#- import_playbook: /deployment/application/stage1.pb.yml
#- import_playbook: /deployment/application/stage3.pb.yml
#- import_playbook: /deployment/application/stage4.pb.yml
#- import_playbook: /deployment/application/stage5.pb.yml
#- import_playbook: /deployment/application/stage6.pb.yml
#- import_playbook: /deployment/application/stage7.pb.yml
- import_playbook: /deployment/application/stage8.pb.yml
- import_playbook: /deployment/application/stage9.pb.yml
- import_playbook: /deployment/application/stage10.pb.yml
- import_playbook: /deployment/application/stage11.pb.yml
and the run again the general.pb.yml
but what I am asking is maybe some way that ansible know the tasks that performed and not verified them again , is it possible ?