Allow the galaxy client to fetch from a url in role version data (#39396)

Currently if the ansible-galaxy client fetches a role from a galaxy
server, it then fetches the role from Github. This change allows a
galaxy server to provide an alternate source url that points to an
archive that contains the role version.
This commit is contained in:
David Davis 2018-04-30 16:47:43 -04:00 committed by Adam Miller
parent c0043444c9
commit 2d21c7da17
2 changed files with 7 additions and 2 deletions

View file

@ -203,7 +203,7 @@ class GalaxyAPI(object):
"""
try:
url = '%s/roles/%d/%s/?page_size=50' % (self.baseurl, int(role_id), related)
url = '%s/roles/%s/%s/?page_size=50' % (self.baseurl, role_id, related)
data = self.__call_galaxy(url)
results = data['results']
done = (data.get('next_link', None) is None)