Skip to content

How to await an event to arise before starting a container. #5176

Answered by davidfowl
Valkozaur asked this question in Q&A
Discussion options

You must be logged in to vote

We have this resource eventing model https://learn.microsoft.com/en-us/dotnet/aspire/app-host/eventing#resource-eventing, that lets you block before a resource starts so you can implement custom waiting like this.

You can also use container files (new feature):

pgAdminContainerBuilder.WithContainerFiles(

PS: Here's a big doc on the resource model https://gist.github.com/davidfowl/b408af870d4b5b54a28bf18bffa127e1. It explains some of these primitives.

Replies: 2 comments 3 replies

Comment options

You must be logged in to vote
0 replies
Answer selected by davidfowl
Comment options

You must be logged in to vote
3 replies
@davidfowl
Comment options

@HuntJason
Comment options

@davidfowl
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants