open-component-model / ocm

Open Component Model (Software Bill of Delivery) Toolset
https://ocm.software
Apache License 2.0
34 stars 23 forks source link

Create uploader for repository type "npm" #633

Closed morri-son closed 8 months ago

morri-son commented 9 months ago

What would you like to be added: It should be possible to upload resources to an "npm" repository after transport. The uploader should use configuration from the credential provider in the OCM library to get the credentials. In addition to that configuration that contains the target npm repository is also required. Therefore a new uploader (https://github.com/open-component-model/ocm-spec/blob/main/doc/02-processing/04-digest.md?plain=1#L649) for this type is required.

It may be helpful to look into how the public Nexus repo implemented it's NPM repository to understand how to persist the blob back as npm after transport: https://github.com/sonatype/nexus-public.

Why is this needed: To be able to mimic the same repository setup on target side that is available on source side, the OCM tooling needs to provide uploaders for all existing technologies, here "npm".