- name: install prometheus include_tasks: install.yml when: function == 'install' - name: add scrape target include_tasks: add_target.yml when: function == 'add_target'