Sdílet prostřednictvím


ContainerResourceBuilderExtensions.WithImage<T> Method

Definition

Allows overriding the image on a container.

public static Aspire.Hosting.ApplicationModel.IResourceBuilder<T> WithImage<T> (this Aspire.Hosting.ApplicationModel.IResourceBuilder<T> builder, string image, string tag = "latest") where T : Aspire.Hosting.ApplicationModel.ContainerResource;
static member WithImage : Aspire.Hosting.ApplicationModel.IResourceBuilder<'T (requires 'T :> Aspire.Hosting.ApplicationModel.ContainerResource)> * string * string -> Aspire.Hosting.ApplicationModel.IResourceBuilder<'T (requires 'T :> Aspire.Hosting.ApplicationModel.ContainerResource)> (requires 'T :> Aspire.Hosting.ApplicationModel.ContainerResource)
<Extension()>
Public Function WithImage(Of T As ContainerResource) (builder As IResourceBuilder(Of T), image As String, Optional tag As String = "latest") As IResourceBuilder(Of T)

Type Parameters

T

Type of container resource.

Parameters

builder
IResourceBuilder<T>

Builder for the container resource.

image
String

Image value.

tag
String

Tag value.

Returns

Applies to