Project

Profile

Help

Story #1536

closed

As a user I would like support for v3/files API so that r10k may work

Added by tarrantmarshall about 8 years ago. Updated almost 5 years ago.

Status:
CLOSED - CURRENTRELEASE
Priority:
Normal
Assignee:
-
Start date:
Due date:
% Done:

100%

Estimated time:
Platform Release:
2.8.0
Groomed:
No
Sprint Candidate:
No
Tags:
Pulp 2
Sprint:
Quarter:

Description

The r10k system for puppet relies on a lot more of the v3 forge API to download modules
Ultimately it needs a list of releases, dependencies and file URI's - utilising what Forge would call their search API. Knowing Search isn't supported yet in the pulp puppet plugin, we could do some partial support to get r10k over the line which is commonly used.

From my discovery so far a new files endpoint, and release needs an extension.

v3/files
v3/releases/<author>-<name>-<version>

r10k makes these requests

GET /v3/files/ceh-nagios-1.2.0.tar.gz
GET /v3/modules/ceh-nagios
GET /v3/releases/ceh-nagios-1.2.0  #Currently gives a 400 error as it expects ?module=. Th

/v3/releases/ceh-nagios-1.2.0 currently gives a 400 error, and the output is different to what /v3/releases?modulename=ceh-nagios would be as the former is for a specific version.

Requests are made by the PuppetForge.gem used by r10k

I have hacked together some of the v3/files API response already to gauge how much of a task this would be and so far r10k seems happy with the mocked/partial response.
https://github.com/tarrantmarshall/pulp_puppet/blob/master/pulp_puppet_plugins/pulp_puppet/forge/views/files.py

Also available in: Atom PDF