lookup plug in file too distributed

0 votes

My lookup plugin is very complex and distributed to be set in a single .py file. What do I do?

Jan 29, 2019 in Ansible by Laksha
619 views

1 answer to this question.

0 votes

Hey @laksha, you can wrap it into a package and add a small helper file, users will only have to do the following:

  1. pip install my_super_lookup
  2. Create ~/.ansible/plugins/lookup/easy_name.py:

    import my_super_lookup
    LookupModule = my_super_lookup.LookupModule
  3. Use with_easy_name: or lookup('easy_name',...) in playbooks
answered Jan 29, 2019 by Kavya

Related Questions In Ansible

0 votes
1 answer

How do I wget a file from web server using shell in the ansible playbook

Hey Ayaan, you could probably use this ...READ MORE

answered Jan 24, 2019 in Ansible by Anushri
3,867 views
0 votes
1 answer

What is the difference between the host file and an inventory file in ansible?

Actually both are same. hosts file is ...READ MORE

answered Feb 12, 2019 in Ansible by Amith
• 140 points
7,253 views
+1 vote
1 answer

Set AWS credentials in boto config file

Go to your boto config file, and ...READ MORE

answered Mar 26, 2019 in Ansible by Raymond
2,488 views
0 votes
1 answer

How to overwrite the content of a file in remote systems using Ansible playbook?

Hi@akhtar, You can find one argument in the ...READ MORE

answered Aug 2, 2020 in Ansible by MD
• 95,440 points
13,303 views
+15 votes
2 answers

Git management technique when there are multiple customers and need multiple customization?

Consider this - In 'extended' Git-Flow, (Git-Multi-Flow, ...READ MORE

answered Mar 27, 2018 in DevOps & Agile by DragonLord999
• 8,450 points
3,520 views
+2 votes
1 answer
0 votes
1 answer

obtain information about a file in windows using ansible playbook

Hey @Travis, you can use the win_stat ...READ MORE

answered Jun 11, 2019 in Ansible by Drake
1,102 views
+1 vote
1 answer
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP