Hey, we ended up writing a function like this:
ctr = ctr.WithExec(exec)
c, err := ctr.ExitCode(ctx)
if err != nil || c != 0 {
panic(fmt.Sprintf("error when executing %v: %v", exec, err))
}
return ctr
}```
I wonder if there's any Dagger-native way of doing this? We had a container on which we executed quite a few commands and one of the first ones had error which we didn't notice early enough and ended up in troubles.
