Skip to content

Azure: CD executions are killed at 30 minutes by the job template ReplicaTimeout #2213

Description

@defangdevs

aca.SetUpJob hardcodes the defang-cd job template's ReplicaTimeout to 30 minutes (src/pkg/clouds/azure/aca/job.go, timeout := int32((30 * time.Minute).Seconds())). This bounds every CD execution on Azure — ups and downs — while the cd binary allows itself 60 minutes (cd/main.go in pulumi-defang, WithTimeoutCause(ctx, 60*time.Minute, ...)).

Result: any Azure deploy or destroy that needs more than 30 minutes is killed by ACA mid-run, even though the CD program would have kept going. Long downs are real (Lio has seen them) and a killed destroy leaves a half-destroyed stack with a possibly locked state.

Also note: aca.JobRequest.Timeout exists but StartJobExecution never reads it — callers passing it (e.g. ByocAzure.runCdCommand passes 30m) get no effect. Either wire it up or remove the field.

Suggested fix: raise the template ReplicaTimeout to 60 minutes to match the cd binary's own ceiling, and make JobRequest.Timeout either functional or gone.

Found while reviewing DefangLabs/pulumi-defang PR 411 (TTL self-destruct), where the scheduled down runs through this same path.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions