Skip to content

Instantly share code, notes, and snippets.

@kshitijcode
Created July 7, 2021 10:40
Show Gist options
  • Select an option

  • Save kshitijcode/2af54490d1ab27bd72d3231c58e2bd62 to your computer and use it in GitHub Desktop.

Select an option

Save kshitijcode/2af54490d1ab27bd72d3231c58e2bd62 to your computer and use it in GitHub Desktop.
public void ConfigureServices(IServiceCollection services)
{
services.AddControllers();
services.AddControllers().AddDapr(builder => builder.UseHttpEndpoint(Configuration.GetValue<string>("DAPR_HTTP_ENDPOINT"))
.UseGrpcEndpoint(Configuration.GetValue<string>("DAPR_GRPC_ENDPOINT")));
services.AddSwaggerGen(c =>
{
c.SwaggerDoc("v1", new OpenApiInfo { Title = "DaprAdventures.PublisherService", Version = "v1" });
});
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment