Skip to content
Docs Try Aspire

Deploy Properties

Class Properties 7 members
Represents the deployment configuration for a Docker service. This class is used to define various aspects such as replication, mode, resource constraints, updates, and restart policies.
Represents the label configurations for a deployable service in Docker.
public LabelSpecs? Labels { get; set; }
This property is used to define additional metadata, typically in the form of key-value pairs, that can be attached to services for organizational or descriptive purposes.
Mode Section titled Mode nullable string?
Gets or sets the deployment mode for the service. Specifies how tasks are scheduled on nodes. Common values include "replicated" for distributing tasks across nodes or "global" for running a task on every node in the cluster.
public string? Mode { get; set; }
Specifies the placement constraints and preferences for service deployment.
public Placement? Placement { get; set; }
The Placement property defines the rules for how the service should be placed on nodes within a Docker Swarm. This includes constraints that must be satisfied and preferences to guide the scheduler.
Replicas Section titled Replicas nullable int?
Represents the number of task replicas for a service node deployment. The replicas define the desired count of independently running instances of the service within the deployment.
public int? Replicas { get; set; }
Represents the resource configurations for a deployable service within Docker.
public Resources? Resources { get; set; }
The Resources class is used to define resources such as CPU and memory that are allocated to or reserved for a service. It includes configurations for both resource limits and reservations.
Specifies the restart policy for a Docker service.
public RestartPolicy? RestartPolicy { get; set; }
The RestartPolicy defines conditions under which the service containers will be restarted, as well as parameters like delay between restarts, maximum restart attempts, and a time window for evaluating restart conditions.
Represents the update configuration used during service deployments.
public UpdateConfig? UpdateConfig { get; set; }
The UpdateConfig property defines the parameters associated with updating services. It allows configuration of update behavior such as parallelism, delays, failure actions, and monitoring.