104 references to AddContainer
Aspire.Hosting (3)
ContainerResourceBuilderExtensions.cs (2)
43
return
AddContainer
(builder, name, image)
429
return builder.
AddContainer
(name, "placeholder") // Image name will be replaced by WithDockerfile.
IDistributedApplicationBuilder.cs (1)
140
/// This example shows the implementation of the <see cref="ContainerResourceBuilderExtensions.
AddContainer
(IDistributedApplicationBuilder, string, string)"/>
Aspire.Hosting.Azure.Tests (17)
AzureBicepProvisionerTests.cs (1)
35
var container = builder.
AddContainer
("foo", "image")
AzureContainerAppsTests.cs (16)
27
builder.
AddContainer
("api", "myimage");
586
builder.
AddContainer
("api", "myimage")
972
builder.
AddContainer
("api", "myimage")
1071
builder.
AddContainer
("api", "myimage")
1185
builder.
AddContainer
("api", "myimage")
1321
builder.
AddContainer
("api", "image")
1497
builder.
AddContainer
("api1", "myimage");
1584
builder.
AddContainer
("api", "myimage")
1682
builder.
AddContainer
("api", "myimage")
1786
builder.
AddContainer
("api", "myimage")
2022
builder.
AddContainer
("api", "myimage")
2041
builder.
AddContainer
("api", "myimage")
2062
builder.
AddContainer
("api", "myimage")
2081
builder.
AddContainer
("api", "myimage")
2101
builder.
AddContainer
("api", "myimage")
2120
builder.
AddContainer
("api", "myimage")
Aspire.Hosting.Containers.Tests (27)
ContainerResourceBuilderTests.cs (8)
16
var redis = builder.
AddContainer
("redis", "redis").WithImage("redis-stack");
24
var redis = builder.
AddContainer
("redis", "redis").WithImage("redis-stack", "1.0.0");
33
var container = builder.
AddContainer
("app", "some-image");
45
var container = builder.
AddContainer
("app", "some-image");
57
var redis = builder.
AddContainer
("redis", "redis").WithImageTag("7.1");
65
var redis = builder.
AddContainer
("redis", "redis").WithImageRegistry("myregistry.azurecr.io");
73
var redis = builder.
AddContainer
("redis", "redis").WithImageSHA256("42b5c726e719639fcc1e9dbc13dd843f567dcd37911d0e1abb9f47f2cc1c95cd");
197
.
AddContainer
("redis", "image")
ContainerResourceTests.cs (7)
18
appBuilder.
AddContainer
("container", "none");
56
appBuilder.
AddContainer
("container", "image:tag");
76
appBuilder.
AddContainer
("container", "imagewithdigest@sha256:01234567890abcdef01234567890abcdef01234567890abcdef01234567890ab");
99
var c1 = appBuilder.
AddContainer
("c1", "image2")
106
var c2 = appBuilder.
AddContainer
("container", "none")
208
appBuilder.
AddContainer
("container", "none")
273
builder.
AddContainer
("containerwithbindmounts", "image/name")
WithDockerfileTests.cs (12)
31
builder.
AddContainer
("testcontainer", "testimage")
62
builder.
AddContainer
("testcontainer", "testimage")
95
builder.
AddContainer
("testcontainer", "testimage")
166
var container = builder.
AddContainer
("testcontainer", "testimage")
261
var container = builder.
AddContainer
("testcontainer", "testimage")
350
builder.
AddContainer
("testcontainer", "testimage")
487
builder.
AddContainer
("mycontainer", "myimage")
514
var container = builder.
AddContainer
("mycontainer", "myimage");
535
var container = builder.
AddContainer
("mycontainer", "myimage")
566
var container = builder.
AddContainer
("mycontainer", "myimage")
597
var container = builder.
AddContainer
("mycontainer", "myimage")
628
var container = builder.
AddContainer
("mycontainer", "myimage")
Aspire.Hosting.Milvus.Tests (1)
AddMilvusTests.cs (1)
113
var container1 = appBuilder.
AddContainer
("container1", "fake")
Aspire.Hosting.Qdrant.Tests (1)
AddQdrantTests.cs (1)
188
var container1 = appBuilder.
AddContainer
("container1", "fake")
Aspire.Hosting.Tests (55)
Dashboard\DashboardResourceTests.cs (4)
64
builder.
AddContainer
("my-container", "my-image");
95
var container = builder.
AddContainer
(KnownResourceNames.AspireDashboard, "my-image");
293
builder.
AddContainer
("my-container", "my-image").WithHttpEndpoint(port: 8080, targetPort: 58080);
336
builder.
AddContainer
("my-container", "my-image").WithHttpEndpoint(port: 8080, targetPort: 58080);
Dcp\DcpExecutorTests.cs (11)
29
builder.
AddContainer
("CustomName", "container").WithOtlpExporter();
447
builder.
AddContainer
("database", "image");
536
builder.
AddContainer
("database", "image");
742
builder.
AddContainer
("database", "image")
777
builder.
AddContainer
("database", "image")
837
var ctr = builder.
AddContainer
("database", "image");
855
builder.
AddContainer
("database", "image")
891
builder.
AddContainer
("database", "image")
928
builder.
AddContainer
("database", "image")
962
builder.
AddContainer
("database", "image");
997
var container = builder.
AddContainer
("database", "image");
DistributedApplicationTests.cs (8)
291
testProgram.AppBuilder.
AddContainer
("redis-cli", "redis")
322
testProgram.AppBuilder.
AddContainer
("redis0", "redis")
411
testProgram.AppBuilder.
AddContainer
("redis0", "redis")
539
testProgram.AppBuilder.
AddContainer
("redis-cli", "redis")
568
testProgram.AppBuilder.
AddContainer
("redis-cli", "redis")
597
testProgram.AppBuilder.
AddContainer
("redis-cli", "redis")
627
testProgram.AppBuilder.
AddContainer
("redis-cli", "redis")
959
var redis = builder.
AddContainer
("dummyRedis", "redis").WithEndpoint("tcp", endpoint =>
HealthCheckTests.cs (2)
23
builder.
AddContainer
("resource", "dummycontainer")
45
builder.
AddContainer
("resource", "dummycontainer")
ManifestGenerationTests.cs (2)
97
var redis = builder.
AddContainer
("redis", "redis");
258
program.AppBuilder.
AddContainer
("testresource", "testresource");
Orchestrator\ApplicationOrchestratorTests.cs (1)
23
var parentResource = builder.
AddContainer
("database", "image");
ProjectResourceTests.cs (1)
571
var c1 = appBuilder.
AddContainer
("c1", "image2")
ResourceCommandAnnotationTests.cs (1)
43
var resourceBuilder = builder.
AddContainer
("name", "image");
Schema\SchemaTests.cs (6)
55
builder.
AddContainer
("mycontainer", "myimage").WithDockerfile(tempContextPath);
68
builder.
AddContainer
("mycontainer", "myimage")
86
builder.
AddContainer
("mycontainer", "myimage")
122
builder.
AddContainer
("foo", "bar").WithContainerRuntimeArgs("one", "two", "three");
161
builder.
AddContainer
("mycontainer", "myimage")
171
builder.
AddContainer
("mycontainer", "myimage")
WaitForTests.cs (2)
21
var throwingResource = builder.
AddContainer
("throwingresource", "doesnotmatter")
23
var dependingContainerResource = builder.
AddContainer
("dependingcontainerresource", "doesnotmatter")
WithEndpointTests.cs (11)
230
var container = builder.
AddContainer
("app", "image")
248
var container = builder.
AddContainer
("app", "image")
269
var container = builder.
AddContainer
("app", "image")
297
var container = builder.
AddContainer
("app", "image")
324
var container = builder.
AddContainer
("app", "image")
351
var container = builder.
AddContainer
("app", "image")
378
var container = builder.
AddContainer
("app", "image")
405
var container = builder.
AddContainer
("app", "image")
432
var container = builder.
AddContainer
("app", "image")
557
var container0 = builder.
AddContainer
("app0", "image")
560
var container1 = builder.
AddContainer
("app1", "image")
WithEnvironmentTests.cs (6)
19
var container = builder.
AddContainer
("container", "image")
182
var container = builder.
AddContainer
("container1", "image")
191
var containerB = builder.
AddContainer
("container2", "imageB")
218
var container = builder.
AddContainer
("container1", "image")
227
var containerB = builder.
AddContainer
("container2", "imageB")
246
var targetBuilder = builder.
AddContainer
("targetContainer", "targetImage");