Share via


ComposeFile.Services Property

Definition

Represents a collection of services defined in a Docker Compose file. Each service is identified by a unique name and contains configuration details as defined by the Service class.

[YamlDotNet.Serialization.YamlMember(Alias="services", DefaultValuesHandling=YamlDotNet.Serialization.DefaultValuesHandling.OmitEmptyCollections)]
public System.Collections.Generic.Dictionary<string,Aspire.Hosting.Docker.Resources.ComposeNodes.Service> Services { get; set; }
[<YamlDotNet.Serialization.YamlMember(Alias="services", DefaultValuesHandling=YamlDotNet.Serialization.DefaultValuesHandling.OmitEmptyCollections)>]
member this.Services : System.Collections.Generic.Dictionary<string, Aspire.Hosting.Docker.Resources.ComposeNodes.Service> with get, set
Public Property Services As Dictionary(Of String, Service)

Property Value

A dictionary where the key is the name of the service (as a string), and the value is a Service object containing the configuration of the service.

Attributes
YamlDotNet.Serialization.YamlMemberAttribute

Remarks

Services are a critical part of the Docker Compose ecosystem and are used to define individual application components. These components can include images, commands, environment variables, ports, volumes, dependencies, and more.

Applies to