3 instantiations of DockerfileBuildAnnotation
Aspire.Hosting (3)
ContainerResourceBuilderExtensions.cs (3)
490var annotation = new DockerfileBuildAnnotation(fullyQualifiedContextPath, fullyQualifiedDockerfilePath, stage); 549var annotation = new DockerfileBuildAnnotation(fullyQualifiedContextPath, tempDockerfilePath, stage) 612var annotation = new DockerfileBuildAnnotation(fullyQualifiedContextPath, tempDockerfilePath, stage)
47 references to DockerfileBuildAnnotation
Aspire.Hosting (15)
ApplicationModel\ResourceExtensions.cs (1)
592return resource is ProjectResource || resource.TryGetLastAnnotation<DockerfileBuildAnnotation>(out _);
ContainerResourceBuilderExtensions.cs (7)
490var annotation = new DockerfileBuildAnnotation(fullyQualifiedContextPath, fullyQualifiedDockerfilePath, stage); 549var annotation = new DockerfileBuildAnnotation(fullyQualifiedContextPath, tempDockerfilePath, stage) 612var annotation = new DockerfileBuildAnnotation(fullyQualifiedContextPath, tempDockerfilePath, stage) 779var annotation = builder.Resource.Annotations.OfType<DockerfileBuildAnnotation>().SingleOrDefault(); 877var annotation = builder.Resource.Annotations.OfType<DockerfileBuildAnnotation>().SingleOrDefault();
Dcp\DcpExecutor.cs (1)
1516if (modelContainerResource.Annotations.OfType<DockerfileBuildAnnotation>().SingleOrDefault() is { } dockerfileBuildAnnotation)
Publishing\ManifestPublishingContext.cs (2)
256if (container.Annotations.OfType<DockerfileBuildAnnotation>().Any()) 304if (container.TryGetAnnotationsOfType<DockerfileBuildAnnotation>(out var annotations) && annotations.Single() is { } annotation)
Publishing\ResourceContainerImageBuilder.cs (4)
213if (resource.TryGetLastAnnotation<DockerfileBuildAnnotation>(out var dockerfileBuildAnnotation)) 339private async Task BuildContainerImageFromDockerfileAsync(IResource resource, DockerfileBuildAnnotation dockerfileBuildAnnotation, string imageName, IPublishingStep? step, ContainerBuildOptions? options, CancellationToken cancellationToken) 480resource.TryGetLastAnnotation<DockerfileBuildAnnotation>(out _));
Aspire.Hosting.Azure (2)
AzurePublishingContext.cs (2)
317if (resource.TryGetLastAnnotation<DockerfileBuildAnnotation>(out var dockerfileBuildAnnotation) &&
Aspire.Hosting.Azure.AppContainers (1)
BaseContainerAppContext.cs (1)
85if (resource.TryGetLastAnnotation<DockerfileBuildAnnotation>(out _))
Aspire.Hosting.Azure.AppService (1)
AzureAppServiceInfrastructure.cs (1)
44if (resource is not ProjectResource && !(resource.IsContainer() && resource.TryGetAnnotationsOfType<DockerfileBuildAnnotation>(out _)))
Aspire.Hosting.Containers.Tests (22)
WithDockerfileTests.cs (22)
622var annotation = Assert.Single(container.Resource.Annotations.OfType<DockerfileBuildAnnotation>()); 637var annotation = Assert.Single(container.Resource.Annotations.OfType<DockerfileBuildAnnotation>()); 653var annotation = Assert.Single(container.Resource.Annotations.OfType<DockerfileBuildAnnotation>()); 668var annotation = Assert.Single(container.Resource.Annotations.OfType<DockerfileBuildAnnotation>()); 684var annotation = Assert.Single(container.Resource.Annotations.OfType<DockerfileBuildAnnotation>()); 699var annotation = Assert.Single(container.Resource.Annotations.OfType<DockerfileBuildAnnotation>()); 715var annotation = Assert.Single(container.Resource.Annotations.OfType<DockerfileBuildAnnotation>()); 730var annotation = Assert.Single(container.Resource.Annotations.OfType<DockerfileBuildAnnotation>()); 754var annotation = Assert.Single(container.Resource.Annotations.OfType<DockerfileBuildAnnotation>()); 786var annotation = Assert.Single(container.Resource.Annotations.OfType<DockerfileBuildAnnotation>()); 836var annotation = Assert.Single(container.Resource.Annotations.OfType<DockerfileBuildAnnotation>());
Aspire.Hosting.Docker (3)
DockerComposePublishingContext.cs (2)
91if (serviceResource.TargetResource.TryGetLastAnnotation<DockerfileBuildAnnotation>(out var dockerfileBuildAnnotation) &&
DockerComposeServiceResource.cs (1)
97if (resourceInstance.TryGetLastAnnotation<DockerfileBuildAnnotation>(out _) || resourceInstance is ProjectResource)
Aspire.Hosting.Kubernetes (3)
KubernetesPublishingContext.cs (2)
75if (serviceResource.TargetResource.TryGetLastAnnotation<DockerfileBuildAnnotation>(out var dockerfileBuildAnnotation) &&
KubernetesResource.cs (1)
135if (!resourceInstance.TryGetLastAnnotation<DockerfileBuildAnnotation>(out _) && resourceInstance is not ProjectResource)