Hi , 
I have a main playbook that uses "include" to call other playbooks.

In one of the playbooks, I have 5 tasks. The second task falls on all my 
servers except for one server - From that point, the entire playbook (main) 
is running only on that server

1. If a task failed on a server - how can I stop the entire process
2. In my case, why the playbook continues to run only on the server that 
was passed the specific task?



- hosts:
    - postgres1
    - cloudera_manager
    - worker
    - master
    - gw
    - kafka
    - repository
    - kafka_master
  become: true
  vars_files:
    - ./cloudera_environment.yml

  tasks:

  - name: update hostname
    include: hostname-update.yml

  - name: create maintenance user
    include: create_maintenance_user.yml

  - name: OS update for supporting cloudera best practice      In this playbook 
task number 2 is faild on all my servers except one server

    include: redhat7_bigdata_best_practice.yml                 Starting task 3 
in till the end of the palybook all tasks are running on that
                                                               specific server
  - name: update repository file
    include: update-yum-repo.yml

  - name: Install rpm packages
    include: install-package.yml


## Install Openjdk 11 ##
- hosts:
    - postgres1
    - cloudera_manager
    - worker
    - master
    - gw
    - repository

  become: true
  vars_files:
    - ./cloudera_environment.yml

  tasks:

  - name: Install rpm packages
    include: install-java11-package.yml

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/384caf13-5c89-4edd-acbf-f10b70312f68%40googlegroups.com.

Reply via email to