-
Notifications
You must be signed in to change notification settings - Fork 249
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
Push component to registry #2536
Comments
This comment was marked as resolved.
This comment was marked as resolved.
Given that Spin can reference a single Wasm blob from a registry, it does make sense to me to enable pushing that to a registry using Spin; even if we do believe that tooling will evolve, until such tool is widespread across languages, I feel pretty strongly that Spin should provide this functionality. |
We could maybe reduce confusion by type-checking that the file implements a |
Spin recently added experimental support for sourcing a component's Wasm from a registry. However, you can't yet upload such a component using
spin registry push
: you have to use a specificoras
incantation. It would be good to have an end-to-end story around this.One possible way of doing this is to extend the use of the
-f
flag to accept a Wasm file, asspin up
now allows. Thusspin registry push ghcr.io/itowlson/fileserver:1.0.0 -f ./target/wasm32-wasi/release/fileserver.wasm
would upload a single Wasm blob, which could then be reused via[component] source = { registry = "ghcr.io", package = "itowlson/fileserver", version = "1.0.0" }
.A risk here is confusion over whether "push a component" pushes the fully configured component or just the Wasm blob. Referencing a file hopefully makes that clear.
On the other hand, it's also arguably not something Spin needs to be involved in, because that could be any Wasm file, it doesn't have to be a Spin component. There should be and, and undoubtedly soon will be, other and more general tooling for that. Anyway jotting it down as a ponderable.
The text was updated successfully, but these errors were encountered: