ansible tags
ansible-playbook example.yml --tags "configuration,packages"
ansible tags
ansible-playbook example.yml --tags "configuration,packages"
ansible tags
tasks:
- yum:
name:
- httpd
- memcached
state: present
tags:
- packages
- template:
src: templates/src.j2
dest: /etc/foo.conf
tags:
- configuration
how to use tags in ansible
# Tags goes at same indentation as name or service:
- name: Create Postgres Container
tags: createcontainer
docker_container:
name: mypostgres
...
# Then in the command line:
ansible-playbook myplaybook.yaml --tags createcontainer
Copyright © 2021 Codeinu
Forgot your account's password or having trouble logging into your Account? Don't worry, we'll help you to get back your account. Enter your email address and we'll send you a recovery link to reset your password. If you are experiencing problems resetting your password contact us