Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ansible-galaxy collection install requires a mandatory -p option #60216

Closed
anshulbehl opened this issue Aug 7, 2019 · 4 comments
Closed

ansible-galaxy collection install requires a mandatory -p option #60216

anshulbehl opened this issue Aug 7, 2019 · 4 comments
Labels
affects_2.9 This issue/PR affects Ansible v2.9 feature This issue/PR relates to a feature request. support:core This issue/PR relates to code supported by the Ansible Engineering Team.

Comments

@anshulbehl
Copy link
Contributor

SUMMARY

-p or --collections-path should not be mandatory and should pick up value of COLLECTIONS_PATH variable.
As a user of collection if I don't know which path ansible is using to load collection I will tend to make mistakes installing the collection to right path.
COLLECTIONS_PATH will make sure the collection will get picked up for sure.

ISSUE TYPE
  • Feature Idea
COMPONENT NAME

COLLECTIONS

ANSIBLE VERSION
ansible 2.9.0.dev0
  config file = /etc/ansible/ansible.cfg
  configured module search path = [u'/home/abehl/.ansible/plugins/modules', u'/usr/share/ansible/plugins/modules']
  ansible python module location = /home/abehl/work/src/anshul_ansible/ansible/lib/ansible
  executable location = /home/abehl/work/src/anshul_ansible/ansible/bin/ansible
  python version = 2.7.16 (default, Apr 30 2019, 15:54:43) [GCC 9.0.1 20190312 (Red Hat 9.0.1-0.10)]

CONFIGURATION

OS / ENVIRONMENT
STEPS TO REPRODUCE

Try installing a collection without giving -p option

EXPECTED RESULTS

if -p provided use provided path, if not provided use COLLECTIONS_PATHS variable

ACTUAL RESULTS

-p is mandatory right now


@sivel
Copy link
Member

sivel commented Aug 7, 2019

It is expected that the user must provide this value, and this was an explicit choice on our part.

Documentation is in the process of being updated currently: #60164

In the future, we may extend this to include some form of default value.

If you have further questions please stop by IRC or the mailing list:

@chrismeyersfsu
Copy link
Member

This would be less painful if the debugging output, when you are testing calling the collection you installed, was more verbose. But, as it stands, the debug output when a collection is not found is not very useful.

@sivel sivel closed this as completed Aug 7, 2019
@anshulbehl
Copy link
Contributor Author

Reopening
@thaumos Can you take a stab as this and please close if this doesn't make sense

@anshulbehl anshulbehl reopened this Aug 7, 2019
@ansibot ansibot added affects_2.9 This issue/PR affects Ansible v2.9 feature This issue/PR relates to a feature request. needs_triage Needs a first human triage before being processed. support:core This issue/PR relates to code supported by the Ansible Engineering Team. labels Aug 7, 2019
@sivel sivel removed the needs_triage Needs a first human triage before being processed. label Aug 8, 2019
@jborean93
Copy link
Contributor

During the intial development for ansible-galaxy collection install we couldn't come to a consensus of what should be the default install location. The end result was to punt the decision and make it a mandatory argument. For now this won't change for the 2.9 release so I am going to close the issue.

@ansible ansible locked and limited conversation to collaborators Oct 8, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
affects_2.9 This issue/PR affects Ansible v2.9 feature This issue/PR relates to a feature request. support:core This issue/PR relates to code supported by the Ansible Engineering Team.
Projects
None yet
Development

No branches or pull requests

5 participants