Facing one issue related to tags in roles. i have specified one tag(create) to run and other tag should skip, but both the tag are executing, can someone explain how to solve this issue.
roles_main.yml
---
- name: roles
hosts: "{{ host }}"
# hosts: localhost
gather_facts: False
become: yes
tasks:
- import_role:
name: "{{ role_name }}"
tags: "{{ tag_name }}"
linux/main.yml
---
- name: in file
import_tasks: in.yml
tags: create
delegate_to: localhost
- name: out file
import_tasks: out.yml
tags: get
delegate_to: localhost
ansible-playbook roles_main.yml -e host=localhost -e ritm_ticket=test1 -e role_name=linux -e tag_name=create -v