published on Wednesday, Nov 18, 2026 by Pulumi
published on Wednesday, Nov 18, 2026 by Pulumi
Updates one or more existing stacks in a stage. Each entry of stacks updates one target stack. Delivery checks out the source of the entry at the commit of the run and runs pulumi up on the target stack.
Create each target stack before the first run. A target stack must be an ordinary stack in the organization of the pipeline.
The entries of a group run together. They can read the new outputs of each other through stack references. The group is one unit for dependencies and retries. A resource that uses an output of one entry waits for the whole group. If one entry fails, a retry runs every entry again. Each entry uses one slot of the concurrent job limit of the organization. A group with more entries than the limit can block itself. Delivery fails it after 2 hours without progress.
If the output of one entry is secret, all outputs of the group are secret.
Example Usage
import * as delivery from "@pulumi/delivery";
new delivery.Stacks("dev", {
stage: dev,
stacks: {
api: { stack: "shop-infra/dev", source: code, directory: "infra", config: { environment: "dev" } },
},
});
Create Stacks Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Stacks(name: string, args: StacksArgs, opts?: ComponentResourceOptions);@overload
def Stacks(resource_name: str,
args: StacksArgs,
opts: Optional[ResourceOptions] = None)
@overload
def Stacks(resource_name: str,
opts: Optional[ResourceOptions] = None,
stacks: Optional[Mapping[str, StacksEntryArgs]] = None,
stage: Optional[Stage] = None)func NewStacks(ctx *Context, name string, args StacksArgs, opts ...ResourceOption) (*Stacks, error)public Stacks(string name, StacksArgs args, ComponentResourceOptions? opts = null)
public Stacks(String name, StacksArgs args)
public Stacks(String name, StacksArgs args, ComponentResourceOptions options)
type: delivery:Stacks
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
resource "delivery_stacks" "name" {
# resource properties
}Parameters
- name string
- The unique name of the resource.
- args StacksArgs
- The arguments to resource properties.
- opts ComponentResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args StacksArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args StacksArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args StacksArgs
- The arguments to resource properties.
- opts ComponentResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args StacksArgs
- The arguments to resource properties.
- options ComponentResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var stacksResource = new Delivery.Stacks("stacksResource", new()
{
Stacks =
{
{ "string", new Delivery.Inputs.StacksEntryArgs
{
Directory = "string",
Source = gitHubSource,
Stack = "string",
Config =
{
{ "string", "string" },
},
Environment =
{
{ "string", "string" },
},
Image = new Delivery.Inputs.ImageArgs
{
Reference = "string",
Credentials = new Delivery.Inputs.ImageCredentialsArgs
{
Password = "string",
Username = "string",
},
},
PreRunCommands = new[]
{
"string",
},
Runtime = workflowsRuntime,
Timeout = "string",
} },
},
Stage = stage,
});
example, err := delivery.NewStacks(ctx, "stacksResource", &delivery.StacksArgs{
Stacks: delivery.StacksEntryMap{
"string": &delivery.StacksEntryArgs{
Directory: pulumi.String("string"),
Source: pulumi.Any(gitHubSource),
Stack: pulumi.String("string"),
Config: pulumi.StringMap{
"string": pulumi.String("string"),
},
Environment: pulumi.StringMap{
"string": pulumi.String("string"),
},
Image: &delivery.ImageArgs{
Reference: pulumi.String("string"),
Credentials: &delivery.ImageCredentialsArgs{
Password: pulumi.String("string"),
Username: pulumi.String("string"),
},
},
PreRunCommands: pulumi.StringArray{
pulumi.String("string"),
},
Runtime: pulumi.Any(workflowsRuntime),
Timeout: pulumi.String("string"),
},
},
Stage: pulumi.Any(stage),
})
resource "delivery_stacks" "stacksResource" {
lifecycle {
create_before_destroy = true
}
stacks = {
"string" = {
directory = "string"
source = gitHubSource
stack = "string"
config = {
"string" = "string"
}
environment = {
"string" = "string"
}
image = {
reference = "string"
credentials = {
password = "string"
username = "string"
}
}
pre_run_commands = ["string"]
runtime = workflowsRuntime
timeout = "string"
}
}
stage = stage
}
var stacksResource = new Stacks("stacksResource", StacksArgs.builder()
.stacks(Map.of("string", StacksEntryArgs.builder()
.directory("string")
.source(gitHubSource)
.stack("string")
.config(Map.of("string", "string"))
.environment(Map.of("string", "string"))
.image(ImageArgs.builder()
.reference("string")
.credentials(ImageCredentialsArgs.builder()
.password("string")
.username("string")
.build())
.build())
.preRunCommands("string")
.runtime(workflowsRuntime)
.timeout("string")
.build()))
.stage(stage)
.build());
stacks_resource = delivery.Stacks("stacksResource",
stacks={
"string": {
"directory": "string",
"source": git_hub_source,
"stack": "string",
"config": {
"string": "string",
},
"environment": {
"string": "string",
},
"image": {
"reference": "string",
"credentials": {
"password": "string",
"username": "string",
},
},
"pre_run_commands": ["string"],
"runtime": workflows_runtime,
"timeout": "string",
},
},
stage=stage)
const stacksResource = new delivery.Stacks("stacksResource", {
stacks: {
string: {
directory: "string",
source: gitHubSource,
stack: "string",
config: {
string: "string",
},
environment: {
string: "string",
},
image: {
reference: "string",
credentials: {
password: "string",
username: "string",
},
},
preRunCommands: ["string"],
runtime: workflowsRuntime,
timeout: "string",
},
},
stage: stage,
});
type: delivery:Stacks
properties:
stacks:
string:
config:
string: string
directory: string
environment:
string: string
image:
credentials:
password: string
username: string
reference: string
preRunCommands:
- string
runtime: ${workflowsRuntime}
source: ${gitHubSource}
stack: string
timeout: string
stage: ${stage}
Stacks Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The Stacks resource accepts the following input properties:
Outputs
All input properties are implicitly available as output properties. Additionally, the Stacks resource produces the following output properties:
- Outputs
Dictionary<string, Immutable
Dictionary<string, object>> - Outputs of each entry, by entry name. They are unknown until the group runs.
- Outputs map[string]map[string]interface{}
- Outputs of each entry, by entry name. They are unknown until the group runs.
- outputs map(map(any))
- Outputs of each entry, by entry name. They are unknown until the group runs.
- outputs Map<String,Map<String,Object>>
- Outputs of each entry, by entry name. They are unknown until the group runs.
- outputs {[key: string]: {[key: string]: any}}
- Outputs of each entry, by entry name. They are unknown until the group runs.
- outputs Mapping[str, Mapping[str, Any]]
- Outputs of each entry, by entry name. They are unknown until the group runs.
- outputs Map<Map<Any>>
- Outputs of each entry, by entry name. They are unknown until the group runs.
Supporting Types
Image, ImageArgs
Container image that a member runs in.- Reference string
- Image reference, for example pulumi/pulumi-nodejs:3.272.0.
- Credentials
Image
Credentials - Credentials for a private registry.
- Reference string
- Image reference, for example pulumi/pulumi-nodejs:3.272.0.
- Credentials
Image
Credentials - Credentials for a private registry.
- reference string
- Image reference, for example pulumi/pulumi-nodejs:3.272.0.
- credentials object
- Credentials for a private registry.
- reference String
- Image reference, for example pulumi/pulumi-nodejs:3.272.0.
- credentials
Image
Credentials - Credentials for a private registry.
- reference string
- Image reference, for example pulumi/pulumi-nodejs:3.272.0.
- credentials
Image
Credentials - Credentials for a private registry.
- reference str
- Image reference, for example pulumi/pulumi-nodejs:3.272.0.
- credentials
Image
Credentials - Credentials for a private registry.
- reference String
- Image reference, for example pulumi/pulumi-nodejs:3.272.0.
- credentials Property Map
- Credentials for a private registry.
ImageCredentials, ImageCredentialsArgs
Credentials for a private registry.StacksEntry, StacksEntryArgs
One target stack that a Stacks resource updates.- Directory string
- Directory of the stack project, relative to the repository root.
- Source
Pulumi.
Delivery. Git Hub Source | Pulumi. Delivery. Git Lab Source | Pulumi. Delivery. Bitbucket Source | Pulumi. Delivery. Azure Dev Ops Source - VCS source to check out. The update uses the commit of the run for this source.
- Stack string
- Target stack as project/stack. It must exist before the first run, in the organization of the pipeline.
- Config Dictionary<string, string>
- Config values that Delivery sets on the target stack before the update. Values are plain strings. Delivery rejects secret values. Keep secrets in the config file of the target stack or in an ESC environment.
- Environment Dictionary<string, string>
- Environment variables for the update, for example cloud credentials. Secret values stay secret. The names PULUMI_ACCESS_TOKEN and PULUMI_BACKEND_URL, and all names that start with DELIVERY_, are reserved.
- Image Image
- Container image that the member runs in. The default is the Pulumi image. Use it to pin the Pulumi CLI or language versions, for example pulumi/pulumi-nodejs:3.272.0. The image needs bash, curl, gzip and the Pulumi CLI on PATH.
- Pre
Run List<string>Commands - Bash commands that run in the project directory after the dependencies are installed and before the Pulumi command or the command of the job. Each command runs as its own step, so environment changes do not carry over to the next step.
- Runtime
Pulumi.
Delivery. Workflows Runtime - Pool that runs the update.
- Timeout string
- Maximum run time of the update, as a Go duration such as 30m. It must be from 5m to 24h in whole seconds. The default is 2h.
- Directory string
- Directory of the stack project, relative to the repository root.
- Source
Git
Hub Source | Git Lab Source | Bitbucket Source | Azure Dev Ops Source - VCS source to check out. The update uses the commit of the run for this source.
- Stack string
- Target stack as project/stack. It must exist before the first run, in the organization of the pipeline.
- Config map[string]string
- Config values that Delivery sets on the target stack before the update. Values are plain strings. Delivery rejects secret values. Keep secrets in the config file of the target stack or in an ESC environment.
- Environment map[string]string
- Environment variables for the update, for example cloud credentials. Secret values stay secret. The names PULUMI_ACCESS_TOKEN and PULUMI_BACKEND_URL, and all names that start with DELIVERY_, are reserved.
- Image Image
- Container image that the member runs in. The default is the Pulumi image. Use it to pin the Pulumi CLI or language versions, for example pulumi/pulumi-nodejs:3.272.0. The image needs bash, curl, gzip and the Pulumi CLI on PATH.
- Pre
Run []stringCommands - Bash commands that run in the project directory after the dependencies are installed and before the Pulumi command or the command of the job. Each command runs as its own step, so environment changes do not carry over to the next step.
- Runtime
Workflows
Runtime - Pool that runs the update.
- Timeout string
- Maximum run time of the update, as a Go duration such as 30m. It must be from 5m to 24h in whole seconds. The default is 2h.
- directory string
- Directory of the stack project, relative to the repository root.
- source
delivery_
git_ hub_ source | delivery_ git_ lab_ source | delivery_ bitbucket_ source | delivery_ azure_ dev_ ops_ source - VCS source to check out. The update uses the commit of the run for this source.
- stack string
- Target stack as project/stack. It must exist before the first run, in the organization of the pipeline.
- config map(string)
- Config values that Delivery sets on the target stack before the update. Values are plain strings. Delivery rejects secret values. Keep secrets in the config file of the target stack or in an ESC environment.
- environment map(string)
- Environment variables for the update, for example cloud credentials. Secret values stay secret. The names PULUMI_ACCESS_TOKEN and PULUMI_BACKEND_URL, and all names that start with DELIVERY_, are reserved.
- image object
- Container image that the member runs in. The default is the Pulumi image. Use it to pin the Pulumi CLI or language versions, for example pulumi/pulumi-nodejs:3.272.0. The image needs bash, curl, gzip and the Pulumi CLI on PATH.
- pre_
run_ list(string)commands - Bash commands that run in the project directory after the dependencies are installed and before the Pulumi command or the command of the job. Each command runs as its own step, so environment changes do not carry over to the next step.
- runtime
delivery_
workflows_ runtime - Pool that runs the update.
- timeout string
- Maximum run time of the update, as a Go duration such as 30m. It must be from 5m to 24h in whole seconds. The default is 2h.
- directory String
- Directory of the stack project, relative to the repository root.
- source
Git
Hub Source | Git Lab Source | Bitbucket Source | Azure Dev Ops Source - VCS source to check out. The update uses the commit of the run for this source.
- stack String
- Target stack as project/stack. It must exist before the first run, in the organization of the pipeline.
- config Map<String,String>
- Config values that Delivery sets on the target stack before the update. Values are plain strings. Delivery rejects secret values. Keep secrets in the config file of the target stack or in an ESC environment.
- environment Map<String,String>
- Environment variables for the update, for example cloud credentials. Secret values stay secret. The names PULUMI_ACCESS_TOKEN and PULUMI_BACKEND_URL, and all names that start with DELIVERY_, are reserved.
- image Image
- Container image that the member runs in. The default is the Pulumi image. Use it to pin the Pulumi CLI or language versions, for example pulumi/pulumi-nodejs:3.272.0. The image needs bash, curl, gzip and the Pulumi CLI on PATH.
- pre
Run List<String>Commands - Bash commands that run in the project directory after the dependencies are installed and before the Pulumi command or the command of the job. Each command runs as its own step, so environment changes do not carry over to the next step.
- runtime
Workflows
Runtime - Pool that runs the update.
- timeout String
- Maximum run time of the update, as a Go duration such as 30m. It must be from 5m to 24h in whole seconds. The default is 2h.
- directory string
- Directory of the stack project, relative to the repository root.
- source
Git
Hub Source | Git Lab Source | Bitbucket Source | Azure Dev Ops Source - VCS source to check out. The update uses the commit of the run for this source.
- stack string
- Target stack as project/stack. It must exist before the first run, in the organization of the pipeline.
- config {[key: string]: string}
- Config values that Delivery sets on the target stack before the update. Values are plain strings. Delivery rejects secret values. Keep secrets in the config file of the target stack or in an ESC environment.
- environment {[key: string]: string}
- Environment variables for the update, for example cloud credentials. Secret values stay secret. The names PULUMI_ACCESS_TOKEN and PULUMI_BACKEND_URL, and all names that start with DELIVERY_, are reserved.
- image Image
- Container image that the member runs in. The default is the Pulumi image. Use it to pin the Pulumi CLI or language versions, for example pulumi/pulumi-nodejs:3.272.0. The image needs bash, curl, gzip and the Pulumi CLI on PATH.
- pre
Run string[]Commands - Bash commands that run in the project directory after the dependencies are installed and before the Pulumi command or the command of the job. Each command runs as its own step, so environment changes do not carry over to the next step.
- runtime
Workflows
Runtime - Pool that runs the update.
- timeout string
- Maximum run time of the update, as a Go duration such as 30m. It must be from 5m to 24h in whole seconds. The default is 2h.
- directory str
- Directory of the stack project, relative to the repository root.
- source
Git
Hub Source | Git Lab Source | Bitbucket Source | Azure Dev Ops Source - VCS source to check out. The update uses the commit of the run for this source.
- stack str
- Target stack as project/stack. It must exist before the first run, in the organization of the pipeline.
- config Mapping[str, str]
- Config values that Delivery sets on the target stack before the update. Values are plain strings. Delivery rejects secret values. Keep secrets in the config file of the target stack or in an ESC environment.
- environment Mapping[str, str]
- Environment variables for the update, for example cloud credentials. Secret values stay secret. The names PULUMI_ACCESS_TOKEN and PULUMI_BACKEND_URL, and all names that start with DELIVERY_, are reserved.
- image Image
- Container image that the member runs in. The default is the Pulumi image. Use it to pin the Pulumi CLI or language versions, for example pulumi/pulumi-nodejs:3.272.0. The image needs bash, curl, gzip and the Pulumi CLI on PATH.
- pre_
run_ Sequence[str]commands - Bash commands that run in the project directory after the dependencies are installed and before the Pulumi command or the command of the job. Each command runs as its own step, so environment changes do not carry over to the next step.
- runtime
Workflows
Runtime - Pool that runs the update.
- timeout str
- Maximum run time of the update, as a Go duration such as 30m. It must be from 5m to 24h in whole seconds. The default is 2h.
- directory String
- Directory of the stack project, relative to the repository root.
- source
delivery:Git
Hub Source | delivery:Git Lab Source | delivery:Bitbucket Source | delivery:Azure Dev Ops Source - VCS source to check out. The update uses the commit of the run for this source.
- stack String
- Target stack as project/stack. It must exist before the first run, in the organization of the pipeline.
- config Map<String>
- Config values that Delivery sets on the target stack before the update. Values are plain strings. Delivery rejects secret values. Keep secrets in the config file of the target stack or in an ESC environment.
- environment Map<String>
- Environment variables for the update, for example cloud credentials. Secret values stay secret. The names PULUMI_ACCESS_TOKEN and PULUMI_BACKEND_URL, and all names that start with DELIVERY_, are reserved.
- image Property Map
- Container image that the member runs in. The default is the Pulumi image. Use it to pin the Pulumi CLI or language versions, for example pulumi/pulumi-nodejs:3.272.0. The image needs bash, curl, gzip and the Pulumi CLI on PATH.
- pre
Run List<String>Commands - Bash commands that run in the project directory after the dependencies are installed and before the Pulumi command or the command of the job. Each command runs as its own step, so environment changes do not carry over to the next step.
- runtime
delivery:Workflows
Runtime - Pool that runs the update.
- timeout String
- Maximum run time of the update, as a Go duration such as 30m. It must be from 5m to 24h in whole seconds. The default is 2h.
Package Details
- Repository
- delivery pulumi/pulumi-delivery
- License
- Apache-2.0
published on Wednesday, Nov 18, 2026 by Pulumi