wasmerio / wapm-cli

📦 WebAssembly Package Manager (CLI)
https://wapm.io/
MIT License
372 stars 26 forks source link

Could you please opensource the registry implementation? #199

Open frank-dspeed opened 4 years ago

frank-dspeed commented 4 years ago

Thanks for proposing a new feature!

Motivation

It would be nice if I could build a local proxy registry as we did it with verdaccio for npm. The idea here is to run a small proxy in front of your registry that supports additional login and private packages. as also acting as an offline registry.

Proposed solution

opensource the full registry implementation so we can run a similar one locally.

Alternatives

Open Source, at last, a 100% Spec for the registry.

Additional context

Add any other context or screenshots about the feature request here.

syrusakbary commented 4 years ago

Hi @frank-dspeed,

Thanks for opening the issue! I'd love to learn more about your use case. Wapm ecosystem is still very young, so we haven't seen yet any enterprise needs for moving wapm on premise (for private and offline registries, for example).

Just to make sure we understand fully the use case, I'd love to know the following: are you currently using wapm? And if so, how moving into a private registry will help you?

Needless to say, all our WAPM services are based on GraphQL, so as long as your server comply with the GraphQL schema all clients will work! (in fact, the wapm-cli already supports this use case).

You can learn more about the WAPM GraphQL schema here: https://docs.wasmer.io/ecosystem/wapm/graphql-api

frank-dspeed commented 4 years ago

@syrusakbary the use case is simple npm equal features and its not only for the enterprise also for developers that have bad internet connections people tend to create tons of projects with a lot of dependencies today directly inside the project.

I simply want that everything is as easy as useable as in the NPM Ecosystem also I wanted to watch into it to consider way's to do Security Management, in the long run, this Ecosystem needs some kind of automated code review Stats all the stuff like update handling all that we got in the NPM World. But this time we need it none commercial, not like NPM :) so opensource and community-driven.

wasm + wasi is the future of the web and the server so it is important to prepare for that.

frank-dspeed commented 4 years ago

but I understand as everything is graphql related we can simply take an existing registry from any other ecosystem and proxy the graphql requests and responses.

it will cost a bit of reverse engineering but fair enough.

martinduke commented 4 years ago

It looks the like we can figure out the API simply by working through the autocomplete https://registry.wapm.io/graphql

Is there really nowhere where this is written down for public consumption?

syrusakbary commented 4 years ago

Is there really nowhere where this is written down for public consumption?

We haven't written anything down, but we can write it if it's useful. What you think would be good to write on? In general GraphQL schemas are self-documenting, but perhaps we are missing some important pieces.

martinduke commented 4 years ago

Is there really nowhere where this is written down for public consumption?

We haven't written anything down, but we can write it if it's useful. What you think would be good to write on? In general GraphQL schemas are self-documenting, but perhaps we are missing some important pieces.

Perhaps I'm just not educated enough on GraphQL. Is there somewhere in the code I can look and see the whole schema?

syrusakbary commented 4 years ago

Here's the dump of the GraphQL schema, that the wapm CLI is using:

https://github.com/wasmerio/wapm-cli/blob/master/graphql/schema.graphql

martinduke commented 4 years ago

Thanks, that's very helpful!