#๐Ÿ‘‹ Hello all! I've been looking into

1 messages ยท Page 1 of 1 (latest)

cyan maple
#

Would you need streaming of stdout/stderr for dagger withExecs? or dagger services? I'm guessing services based on the link you sent but double checking.

Adding an API to services that supports streams like that would be very cool, but I'll warn may be a very large+complex effort, even if we find some shortcuts.

One thing that comes to mind right away is somehow hooking into telemetry streams (i.e. the way we show live updating logs in the TUI/cloud). I guess it depends on exactly how you need to read the streams for your use case

gentle hare
#

dagger services, ideally, as I think that they're more analogous to docker containers, but hopefully we'd be able to leverage anything we do for withExecs as well

assuming this is what you're referring to by "telemetry streams"--i tried using the *OTEL*LOGS* env vars before, but they don't seem to work with dagger-in-dagger/experimentalPrivilegedNesting (see https://discord.com/channels/707636530424053791/1431058770791759932). I think that would work if we could fix that or get it working another way (and also comes with builtin timestamps which would be useful for filtering logs for the docker logs API call). it would have the downside of no stdin streaming, but that'd be an OK first pass (and I think would work with kind as well). it also wasn't clear to me how to tie the log entries back to a service or container

with regards to it being very large and complex, I don't doubt you but I am curious why we wouldn't be able to take advantage of the stdin/out/err streaming that the terminal functions already use, specifically this bit: https://github.com/dagger/dagger/blob/b22f7708d4e0115dda35152ed6a0ba4faa760cd8/core/terminal.go#L68-L103. I admit a lot of confusion because the streams that get passed to the service there appear to come from buildkit: https://github.com/dagger/dagger/blob/b22f7708d4e0115dda35152ed6a0ba4faa760cd8/core/terminal.go#L202-L214. that doesn't explain to me how the client's terminal gets connected, but apparently it works so who am I to question?