Skip to content
Discussion options

You must be logged in to vote

Is there a way to tell Aspire to use Temporal:Endpoint when injecting the connection string env var?

WithReference() is highly opinionated in how it injects values - if those opinions don't work for you, you can inject your own environment variables. In your case you don't need to implement IResourceWithConnectionString and can wire up the endpoint by itself:

api
.WithEnvironment("Temporal__Endpoint", $"{temporal.GetEndpoint("http").Property(EndpointProperty.HostAndPort)}");

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@JobaDiniz
Comment options

@afscrome
Comment options

Answer selected by davidfowl
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