# Limit and selection of group with dynamic inventory

**URL:** <https://forum.ansible.com/t/limit-and-selection-of-group-with-dynamic-inventory/29304>\
**Category:** Ansible Project\
**Created:** [December 19, 2018, 5:46pm UTC](https://forum.ansible.com/t/limit-and-selection-of-group-with-dynamic-inventory/29304 "2018-12-19T17:46:56Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Mehul\_Ved](https://avatars.discourse-cdn.com/v4/letter/m/73ab20/32.png) [@Mehul\_Ved](https://forum.ansible.com/u/Mehul_Ved)\
**Post date:** [December 19, 2018, 5:46pm UTC](https://forum.ansible.com/t/limit-and-selection-of-group-with-dynamic-inventory/29304/1 "2018-12-19T17:46:56Z")

</div>

Hello,  
I have a setup in google cloud which has been working very well with Ansible. Till last week, we had only one “environment” per machine. Each environment was marked by a network tag which ansible would pick up while using limit. This worked beautifully.  
Now, we are trying to consolidate some machines, ones that have our database. Thus, we have 2 environments together e.g. tag\_dev and tag\_test on one machine.  
This has caused a bug where one of my play fails because ansible always picks a particular tag.  
$ cat inventory/group\_vars/tag\_dev
