-
Notifications
You must be signed in to change notification settings - Fork 23.7k
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: Keep clone of repositories #12353
Comments
This might be best implemented as an option in the .yml file (e.g. develop: true) to clone and fetch/(merge/warn) on particular roles. |
It looks like there was an attempt to do this already. The PR is still pending, and seemed to be waiting for v2. |
PR was closed, this feature has not been implemented. |
Just to elaborate, this was not blocked or rejected, rather because of time/development/release issues. So working on a PR for this feature might still be worthwhile. |
@muelli Greetings! Thanks for taking the time to open this issue. In order for the community to handle your issue effectively, we need a bit more information. Here are the items we could not find in your description:
Please set the description of this issue with this template: |
Just to be clear, is the ask to use a flag or option within ansible-galaxy to do a git clone as opposed to just downloading a tarball? |
This should be a flag for the |
I would have to disagree with @bbaassssiiee. while you are correct that this option would primarily be used by maintainers/tool smiths, Many of them will likely (and hopefully do) have automation in place as part of their validation flow. using tools like Ansible Tower/AWX which supports the requirements.yml convention, but doesn't allow you to modify the command that is executed to download the roles. As a result, an option in the requirements.yml file would be the best choice to provide this feature. Additionally, for public repos, it could aid in the collaborative development of roles, allowing for easier PR back to the master branch. |
Agree with @bbaassssiiee Automation flows should exist, but I don't think developers should be coding on roles checked out by tower.
|
e224039 is helpful; thanks. Maybe If I have this requirements.yml:
When I do: ansible-galaxy install -v -g --roles-path=./roles -r ./requirements.yml ansible-galaxy downloads archives by default. But it could instead lookup the current repo url and do a full or a shallow clone; thus making it that much easier to send PRs to helpful role maintainers. |
ISSUE TYPE
Feature Idea
COMPONENT NAME
core
ANSIBLE VERSION
2.1
CONFIGURATION
OS / ENVIRONMENT
SUMMARY
I'd appreciate if I could use ansible-galaxy to download the git repositories and keep them.
Right now ansible-galaxy does, e.g. git archive to get the contents and then discards the cloned git repository.
I'd like to keep the git repository, because I can then track changes more easily.
STEPS TO REPRODUCE
EXPECTED RESULTS
ACTUAL RESULTS
The text was updated successfully, but these errors were encountered: