5 ms·
Does anyone have a good explanation for what Docker+WASM actually is? This announcement explains what WASM is and what Docker is, but I already knew both of tho
by lolinder 4y ago
Does anyone have a good explanation for what Docker+WASM actually is? This announcement explains what WASM is and what Docker is, but I already knew both of those and am still confused about what Docker+WASM is. Is it just wrapping a WASM binary in a Docker container?
- theplumber 4y agoI guess it's a wasm runtime. Basically a way to execute a wasm binary just like you use docker to execute a x64 binary
- stoplying1 4y agoExcept that would've been too easy to understand, and instead seems like they're using wasmedge anyway. Needlessly confusing, why do companies do this?
- theplumber 4y agoA reason could be standardised build/deployment/testing.
- deleted 4y ago[deleted]
- timanglade 4y ago"Docker+Wasm" is just a shorthand for the Technical Preview build, which allows you to build both traditional container apps, as well as Wasm apps. Behind the scenes, we try to let Wasm apps be developed largely without interference from any container technology — just giving you a good local environment you can use to code against. That said, if you want, we do offer the ability to run Wasm apps within a Docker Compose application. We do also offer the possibility to package Wasm apps within an OCI image, with an embedded Wasm runtime (WasmEdge) so you can a) easily share these via an image registry like Docker Hub, AWS ECR, etc. and b) easily run this anywhere you’d run a container. That said it’s not mandatory, and if you want the benefits of (a) without the benefits of (b) you can easily unpack the image to just get the Wasm payload and run that however you want. We dove into the details of the approach at Kubecon today, and the video should be coming out shortly.
- stoplying1 4y agoThis seems like a good way to muddle the remaining value prop that docker has. I have zero idea why I'd want wasm via docker tooling vs what exists, especially as people more more and more to not-docker for building and running their containers. I think I see what someone is trying to do, but I don't know any dev looking for this or having a problem solved by it.
- timanglade 4y ago> I don't know any dev looking for this or having a problem solved by it. Judging by the reception at KubeCon & elsewhere today, we think at least some folks are excited by it. But it’s still early, and who knows, you may be right in the end. We launched this as a technical preview to test a hypothesis and learn from it, and so far the interactions from this HN thread alone have been greatly helpful.
- heavyset_go 4y agoWhy were they excited? What use cases does this address? Is the intention to containerize WASM binaries and manage them with Docker like you would any other container? Genuine questions, I'm just trying to understand what this feature is and why someone would want to use it.
- timanglade 4y agoI tried to answer this above[0]. Instead of trying to explain it again, I’d encourage you to give it a try[1], and if after going through the 5-minute tutorial you still don’t get the point then a) maybe we messed up (and I’ll be sorry for having wasted your time!) or b) maybe it’s not for you (and I’ll also be sorry I wasted your time). It took me a while to wrap my head around this Docker+Wasm thing too when I first heard about it internally — then again it took me months to wrap my head around my first demo of Docker, so maybe I’m just dense! [0]: https://news.ycombinator.com/item?id=33324093 https://news.ycombinator.com/item?id=33324093 [1]: https://docs.docker.com/desktop/wasm/ https://docs.docker.com/desktop/wasm/
- artdigital 4y agoI read through it at first and thought it was the docker desktop app rewritten in wasm instead of electron I guess it’s a wasm runner
- MuffinFlavored 4y agoSo Wasmer but... OCI/Docker?
- enos_feedler 4y agoI was just coming here to write a comment that says I think the blog post is missing a section. Or it at least feels that way. At the heading “How do I get the technical preview?” I was expecting a heading that says “What is Docker+WASM?” Glad I am not the only one
- Matthias247 4y agoI don't really get it either. It's kind of missing which interfaces are actually provided to the WASM script, and how the magic webserver that is described in the docs is working. Most WASI implementation so far seem to just make a stdin and stdout available for a WASM program - which wouldn't really be enough to run a webserver in it. Is this example running a non-wasm webserver that then proxies to WASM modules? Is that wasmedge? Or does wasmedge really make syscalls like accept() available to the module? If it's the latter, how could it actually do something meaningful without threading - given any accept() would block the whole module? Run in non-blocking mode and expect the whole WASM module to be written in async style? I know these are lots of questions - but they seem rather fundamental to what you could actually use the system for.
- bjconlan 4y agoYeah, I'm with you on this. I'm hoping that there is more to come soon that might flesh out this story. (I mean, surely just having an entrypoint into wasmtime + args or runtime of choice) gets these things inline with existing docker goals. I think this is mostly a land grab to have docker image repositories be the distribution method of choice for wasi.
- reubenmorais 4y ago> Is this example running a non-wasm webserver that then proxies to WASM modules? Is that wasmedge? Or does wasmedge really make syscalls like accept() available to the module? > If it's the latter, how could it actually do something meaningful without threading - given any accept() would block the whole module? Run in non-blocking mode and expect the whole WASM module to be written in async style? The docs here show how it works: https://wasmedge.org/book/en/write_wasm/rust/networking.html https://wasmedge.org/book/en/write_wasm/rust/networking.html
- mmgutz 4y agoThe missing piece. WASM, specificially WASM run time environments, have the potential to replace containers in the future. If you can target WASM with Go, Rust, Python, C, C++ ... then you don't need containers at all. BTW, the two WASM runtimes jockeying for position are wasmtime and wasmer. It looks like Docker is getting behind wasmtime.
- cropcirclbureau 4y agoThe article states that they're using the wasmedge[0] runtime actually. [0]: https://github.com/WasmEdge/WasmEdge/ https://github.com/WasmEdge/WasmEdge/